feat: log user id

This commit is contained in:
chenos 2022-11-13 17:14:14 +08:00
parent c9baf3f02c
commit dcb5a71b92

View File

@ -29,9 +29,11 @@ async function findUserByToken(ctx: Context) {
id: userId, id: userId,
}, },
}); });
ctx.logger.info(`Current user id: ${userId}`);
return user; return user;
} catch (error) { } catch (error) {
console.log(error); console.log(error);
ctx.logger.error(error);
return null; return null;
} }
} }