Avoid re-fetching user if not requesting extra fields

This commit is contained in:
Rory& committed 2025-12-18 01:24:37 +01:00
1 parent df8f8a57af
commit e2de706abf
12 files changed
+21 -24

No files matched your search

+1 -1
View File
@@ -41,7 +41,7 @@ router.post("/", route({}), async (req: Request, res: Response) => {
},
} as InteractionCreateEvent);
const user = await User.findOneOrFail({ where: { id: req.user_id } });
const user = req.user;
const interactionData: Partial<InteractionCreateSchema> = {
id: interactionId,