Skip to content

Commit

Permalink
Merge pull request #35 from nuorder/add-verb-patch
Browse files Browse the repository at this point in the history
Support PATCH request
  • Loading branch information
ryanashcraft authored Mar 11, 2017
2 parents 6fc3412 + 9207b5b commit 0bcafa4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/constants/http-methods.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ export const GET = 'GET';
export const HEAD = 'HEAD';
export const POST = 'POST';
export const PUT = 'PUT';
export const PATCH = 'PATCH';
3 changes: 3 additions & 0 deletions src/middleware/query.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ const createRequest = (url, method) => {
case httpMethods.PUT:
request = superagent.put(url);
break;
case httpMethods.PATCH:
request = superagent.patch(url);
break;
case httpMethods.DELETE:
request = superagent.del(url);
break;
Expand Down

0 comments on commit 0bcafa4

Please sign in to comment.