chore: no default export

This commit is contained in:
Agusti Fernandez Pardo committed 2022-03-29 03:23:22 +02:00
1 parent 75e635cb37
commit 3011e0ecf7
9 files changed
+29 -19

No files matched your search

+1 -1
View File
@@ -12,4 +12,4 @@ const withMiddleware = label(
["sentry","verifyApiKey"] // <-- Provide a list of middleware to call automatically
);
export default withMiddleware;
export { withMiddleware };
+3
View File
@@ -5,6 +5,9 @@ import { z } from "zod";
// at different endpoints that require this validation.
const schemaQueryIdAsString = z
.object({
// since we added apiKey as query param this is required by next-validations helper
// for query params to work properly and not fail.
apiKey: z.string().cuid(),
// since nextjs parses query params as strings,
// we need to cast them to numbers using z.transform() and parseInt()
id: z.string()
@@ -5,6 +5,9 @@ import { z } from "zod";
// at different endpoints that require this validation.
const schemaQueryIdParseInt = z
.object({
// since we added apiKey as query param this is required by next-validations helper
// for query params to work properly and not fail.
apiKey: z.string().cuid(),
// since nextjs parses query params as strings,
// we need to cast them to numbers using z.transform() and parseInt()
id: z