diff --git a/dist/habitrpg-shared.js b/dist/habitrpg-shared.js index cea19fd987..4c13051534 100644 --- a/dist/habitrpg-shared.js +++ b/dist/habitrpg-shared.js @@ -10983,10 +10983,14 @@ var process=require("__browserify_process");(function() { return cb(null, req); }, updateTask: function(req, cb) { + var _base; if (!(req.params.id && user.tasks[req.params.id])) { return typeof cb === "function" ? cb("Task not found") : void 0; } _.merge(user.tasks[req.params.id], req.body); + if (typeof (_base = user.tasks[req.params.id]).markModified === "function") { + _base.markModified('tags'); + } return typeof cb === "function" ? cb(null, req) : void 0; }, deleteTask: function(req, cb) { diff --git a/script/index.coffee b/script/index.coffee index 71b98083d4..fa9f6f215c 100644 --- a/script/index.coffee +++ b/script/index.coffee @@ -243,7 +243,7 @@ api.newChatMessages = (messages, lastMessageSeen) -> ### are any tags active? ### -api.noTags = (tags) -> _.isEmpty(tags) or _.isEmpty(_.filter( tags, (t) -> t ) ) +api.noTags = (tags) -> _.isEmpty(tags) or _.isEmpty(_.filter(tags, (t)->t)) ### Are there tags applied? @@ -336,6 +336,7 @@ api.wrap = (user) -> updateTask: (req, cb) -> return cb?("Task not found") unless req.params.id and user.tasks[req.params.id] _.merge user.tasks[req.params.id], req.body + user.tasks[req.params.id].markModified? 'tags' cb? null, req deleteTask: (req, cb) ->