Allow editing/deleting of comments and threads

This commit is contained in:
James Allen
2017-01-24 15:44:32 +01:00
parent a997bf9c01
commit fa63eb6947
9 changed files with 184 additions and 4 deletions
@@ -53,3 +53,12 @@ module.exports = ThreadManager =
resolved: true
}
}, callback
deleteThread: (project_id, thread_id, callback = (error, room_id) ->) ->
@findOrCreateThread project_id, thread_id, (error, room) ->
return callback(error) if error?
db.rooms.remove {
_id: room._id
}, (error) ->
return callback(error) if error?
return callback null, room._id