修复刷新token失效

This commit is contained in:
COOL 2023-07-28 18:38:28 +08:00
parent c27c0ff39f
commit 0a00cdf46e

View File

@ -177,9 +177,9 @@ export class UserLoginService extends BaseService {
throw new CoolCommException('token类型非refreshToken');
}
const userInfo = await this.userInfoEntity.findOneBy({
id: info['userId'],
id: info['id'],
});
return this.token(userInfo);
return this.token({ id: userInfo.id });
} catch (e) {
throw new CoolCommException(
'刷新token失败请检查refreshToken是否正确或过期'