UNPKG

@azure-utils/storybooks

Version:

Utils to upload and manage Storybooks via Azure Functions and storage.

15 lines (13 loc) 639 B
import { responseError } from "./store-BL4RNiEp.mjs"; //#region src/utils/validators.ts function validateBuildUploadZipBody(request, context) { const body = request.body; if (!body) return responseError("Request body is required", context, 400); const contentLength = request.headers.get("Content-Length"); if (!contentLength) return responseError("Content-Length header is required", context, 411); if (parseInt(contentLength, 10) === 0) return responseError("Request body should have length > 0", context, 400); return void 0; } //#endregion export { validateBuildUploadZipBody }; //# sourceMappingURL=validators-C1FF8po_.mjs.map