Skip to content

Commit

Permalink
Rename 'del' to 'delete' due to express4 deprec
Browse files Browse the repository at this point in the history
  • Loading branch information
Ilya Radchenko committed Dec 22, 2014
1 parent 98dde5e commit 05044c5
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/namespace.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ function join(one, two) {
function namespace(app, prefix) {
var middleware = [].slice.call(arguments, 2)
function route(method) {
if (method === 'del') {
method = 'delete';
}

var args = [].slice.call(arguments, 1)
return app[method].apply(app, [join(prefix, args.shift())].concat(middleware.concat(args)))
}
Expand Down

0 comments on commit 05044c5

Please sign in to comment.