Merge remote-tracking branch 'origin/sk-admin-panel-projects'

GitOrigin-RevId: 56f17fe3bec6252bd3d933899e540813550a36ff
This commit is contained in:
Douglas Lovell
2019-01-24 12:13:16 +00:00
committed by sharelatex
parent bd9adbae52
commit d2bccbec25
2 changed files with 20 additions and 0 deletions
@@ -57,3 +57,13 @@ module.exports =
if err?
logger.err err:err, "error setting brandVariationId"
callback()
unsetBrandVariationId: (project_id, callback = ()->)->
logger.log project_id:project_id, "unsetting the brand variation id"
conditions = {_id:project_id}
update = {$unset: {brandVariationId: 1}}
Project.update conditions, update, {}, (err)->
if err?
logger.err err:err, "error unsetting brandVariationId"
return callback(err)
callback()