Fixed 404 error when deleting/retrying a task caused by recent change in node's implementation of querystring.unescape.
This commit is contained in:
1 parent
2932b9ab6d
commit
41740cbf0b
1 file changed
+1
-1
+1
-1
@@ -244,7 +244,7 @@ listener = (request, response) ->
|
|||||||
else if TASKS_REGEX.test(urlParts.pathname)
|
else if TASKS_REGEX.test(urlParts.pathname)
|
||||||
r = TASKS_REGEX.exec(urlParts.pathname)
|
r = TASKS_REGEX.exec(urlParts.pathname)
|
||||||
taskId = mongodb.ObjectID(querystring.unescape(r[1]))
|
taskId = mongodb.ObjectID(querystring.unescape(r[1]))
|
||||||
action = try querystring.unescape(r[2])
|
action = r[2]
|
||||||
if not action? or action is '/'
|
if not action? or action is '/'
|
||||||
if request.method == 'DELETE'
|
if request.method == 'DELETE'
|
||||||
db.tasksCollection.remove({'_id' : taskId}, (err, removedCount) ->
|
db.tasksCollection.remove({'_id' : taskId}, (err, removedCount) ->
|
||||||
|
|||||||
Reference in new issue
Block a user