Skip to content

Commit 56e1e0a

Browse files
committed
fix: CI
1 parent 0ea4405 commit 56e1e0a

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

server/src/firebase/auth/lib.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ type DecodedIdToken = admin.DecodedIdToken;
1111
// THROWS: if idToken is not present in request cookie, or when the token is not valid.
1212
export async function getGUID(c: Context): Promise<GUID> {
1313
const idToken = c.req.header("Authorization");
14-
if (typeof idToken !== "string") error("token not found in query", 401);
14+
if (typeof idToken !== "string") error("token not found in header", 401);
1515
return await getGUIDFromToken(idToken);
1616
}
1717

server/src/index.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,10 @@ if (corsOptions.origin.length > 1) {
3030
const app = new Hono()
3131
.onError((err, c) => {
3232
if (err instanceof HTTPException) {
33-
throw err;
33+
console.log(err);
34+
return c.json({ error: err.message }, err.status);
3435
}
35-
console.log(err);
36+
console.error(err);
3637
return c.json({ error: err }, 500);
3738
})
3839

0 commit comments

Comments
 (0)