Skip to content

Scheduling infrastructure for absolutely everyone.

fix

Agusti Fernandez Pardo5b65bd1b6605
diff --git a/lib/helpers/verifyApiKey.ts b/lib/helpers/verifyApiKey.ts
index 38fa6b44c36..11d481815e8 100644
--- a/lib/helpers/verifyApiKey.ts
+++ b/lib/helpers/verifyApiKey.ts
@@ -40,5 +40,6 @@ export const verifyApiKey: NextMiddleware = async (req, res, next) => {
if (!apiKey.userId) return res.status(404).json({ error: "No user found for this apiKey" });
/* We save the user id in the request for later use */
req.userId = apiKey.userId;
+ console.log(`User ${apiKey.userId} verified`);
await next();
};
diff --git a/pages/api/event-types/index.ts b/pages/api/event-types/index.ts
index 786d4453f30..57ebba1ce48 100644
--- a/pages/api/event-types/index.ts
+++ b/pages/api/event-types/index.ts
@@ -37,8 +37,16 @@ async function createOrlistAllEventTypes(
select: { eventTypes: true },
})
.catch((error) => res.status(404).json({ message: "No event types were found", error }));
+<<<<<<< HEAD
if (data) res.status(200).json({ event_types: data.eventTypes });
+=======
+ console.log(`userid is: ${userId}`, "eventTypes:", data);
+ // const event_types = data.map(
+ // async (eventType) => await schemaEventTypeReadPublic.safeParseAsync(eventType)
+ // );
+ if (data) res.status(200).json({ event_types: data });
+>>>>>>> 6099bfb (fix: more logging)
else
(error: Error) =>
res.status(404).json({