feat: 初始化项目用户初始化修改
This commit is contained in:
@@ -12,7 +12,9 @@ app
|
||||
.define(async (ctx) => {
|
||||
const state = ctx.state?.tokenUser || {};
|
||||
const { id } = state;
|
||||
const user = await User.findByPk(id);
|
||||
const user = await User.findByPk(id, {
|
||||
logging: false,
|
||||
});
|
||||
if (!user) {
|
||||
throw new CustomError(500, 'user not found');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user