fix: log 500 errors

This commit is contained in:
Bereket Engida
2024-09-08 09:52:52 +03:00
parent 0ef530cfd1
commit 0b00a504c1

View File

@@ -190,11 +190,7 @@ export const router = <C extends AuthContext, Option extends BetterAuthOptions>(
...middlewares,
],
onError(e) {
if (e instanceof APIError) {
if (e.status === "INTERNAL_SERVER_ERROR") {
logger.error(e);
}
}
logger.error(e);
},
});
};