Skip to content

Commit

Permalink
http: fix PATCH
Browse files Browse the repository at this point in the history
"If you want to use a custom method (like PATCH), you should uppercase it yourself."

https://developer.mozilla.org/en-US/docs/Web/API/fetch#parameters
  • Loading branch information
fredericosilva committed Apr 19, 2023
1 parent fffcb78 commit 8e67ad2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/cli-core/lib/http.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export default (device, logger) => {
};

const request = async (method, uri, options) => {
const resp = await baseRequest(method, uri, options);
const resp = await baseRequest(method.toUpperCase(), uri, options);
const type = resp.headers.get('content-type');
const encoding = resp.headers.get('transfer-encoding');

Expand Down

0 comments on commit 8e67ad2

Please sign in to comment.