This commit is contained in:
Scott Erickson 2014-07-09 10:10:43 -07:00
parent d22e8dbde1
commit a7690f0931

View file

@ -62,7 +62,7 @@ PatchHandler = class PatchHandler extends Handler
return unless watchers?.length return unless watchers?.length
User.find({_id: {$in: watchers}}).select({email: 1, name: 1}).exec (err, watchers) => User.find({_id: {$in: watchers}}).select({email: 1, name: 1}).exec (err, watchers) =>
for watcher in watchers for watcher in watchers
@sendPatchCreatedEmail req.user, watcher, doc, doc.targetLoaded, req.body.editPath @sendPatchCreatedEmail req.user, watcher, doc, doc.targetLoaded, req.headers['x-current-path']
sendPatchCreatedEmail: (patchCreator, watcher, patch, target, editPath) -> sendPatchCreatedEmail: (patchCreator, watcher, patch, target, editPath) ->
# return if watcher._id is patchCreator._id # return if watcher._id is patchCreator._id