Skip to content

Commit

Permalink
Add patch wrapper
Browse files Browse the repository at this point in the history
  • Loading branch information
nogorilla committed May 1, 2018
1 parent bbefe73 commit 9f9532d
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,15 @@ class LambdaRouter {
this._wrap('GET', path, hdlr);
}

/**
* Add handler for patch route
* @param {String} path
* @param {Function} hdlr - list of handlers to call in succession
*/
patch(path, ...hdlr) {
this._wrap('PATCH', path, hdlr);
}

/**
* Add handler for post route.
* @param {String} path
Expand Down

0 comments on commit 9f9532d

Please sign in to comment.