From ae107974d1b22bd6eaf7e383b7be75fac05320e7 Mon Sep 17 00:00:00 2001 From: kumavis Date: Sat, 6 May 2017 15:45:39 -0700 Subject: [PATCH 1/2] request-api allow the http method to be specified via `options.method = 'GET'` --- src/request-api.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/request-api.js b/src/request-api.js index 6cb852fec..3c5fc035d 100644 --- a/src/request-api.js +++ b/src/request-api.js @@ -96,7 +96,7 @@ function requestAPI (config, options, callback) { // this option is only used internally, not passed to daemon delete options.qs.followSymlinks - const method = 'POST' + const method = options.method || 'POST' const headers = {} if (isNode) { From bc071953a517433e73c5cd551137893165004b24 Mon Sep 17 00:00:00 2001 From: kumavis Date: Sat, 6 May 2017 15:47:42 -0700 Subject: [PATCH 2/2] block.get - use http method GET to conform to the spec --- src/api/block.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/api/block.js b/src/api/block.js index 965f423d8..a6bd2ebba 100644 --- a/src/api/block.js +++ b/src/api/block.js @@ -47,6 +47,7 @@ module.exports = (send) => { } const request = { + method: 'GET', path: 'block/get', args: args, qs: opts