whole create flow with error handling and such

This commit is contained in:
talksik
2022-06-11 09:45:47 -05:00
parent 3342654431
commit e39316eeff
5 changed files with 21 additions and 10 deletions
+1 -1
View File
@@ -26,7 +26,7 @@ app.use('/api/conversations', getConversationRoutes());
app.use((err: Error, req: Request, res: Response, next: NextFunction) => {
// use logger or sentry
if (!res.statusCode) res.status(500);
if (res.statusCode === 200) res.status(500);
return res.json(new NirvanaResponse(undefined, err, err.message));
});