📅  最后修改于: 2022-03-11 15:02:21.135000             🧑  作者: Mango
async validateUser(email: string, password: string): Promise {
const user = await this.usersService.findOne({ email });
if (user && await compare(password, user.password))
{
return plainToClass(UserWithoutPassword, user.toObject());
}
return null;
}