This commit is contained in:
Tyler Renelle
2013-09-09 00:13:11 -04:00
parent 4caec6f737
commit 1bcdcf8590
2 changed files with 2 additions and 2 deletions

View File

@@ -604,7 +604,7 @@ api.deleteTag = function(req, res){
var i = _.findIndex(user.tags, {id:req.params.tid});
if (~i) {
var tag = user.tags[i];
delete user.filters[tid];
delete user.filters[tag.id];
user.tags.splice(i,1);
// remove tag from all tasks
_.each(user.tasks, function(task) {

View File

@@ -239,7 +239,7 @@ UserSchema.methods.toJSON = function() {
delete doc["#{type}Ids"]
});
delete doc.tasks
//doc.filters = {};
doc.filters = {};
return doc;
};