changed update to updateOne (#13932)

This commit is contained in:
Natalie L
2022-04-15 17:20:37 -04:00
committed by GitHub
parent b7a6dd9706
commit 3492549081

View File

@@ -40,7 +40,7 @@ async function deleteHabiticaData (user, email) {
'auth.local.passwordHashMethod': 'bcrypt',
};
if (!user.auth.local.email) set['auth.local.email'] = `${user._id}@example.com`;
await User.update(
await User.updateOne(
{ _id: user._id },
{ $set: set },
);