mirror of
https://github.com/naturalcrit/homebrewery.git
synced 2026-01-08 18:22:40 +00:00
swap usage of delete on possible Mongoose object for setting the value to undefined
This commit is contained in:
@@ -183,7 +183,7 @@ const updateBrew = async (req, res)=>{
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
delete brew.googleId;
|
brew.googleId = undefined;
|
||||||
} else if(!brew.googleId && transferToGoogle) {
|
} else if(!brew.googleId && transferToGoogle) {
|
||||||
brew.googleId = await newGoogleBrew(req.account, excludeGoogleProps(_.clone(brew)), res)
|
brew.googleId = await newGoogleBrew(req.account, excludeGoogleProps(_.clone(brew)), res)
|
||||||
.catch((err)=>{
|
.catch((err)=>{
|
||||||
|
|||||||
Reference in New Issue
Block a user