(options, callback)
| 254 | return response |
| 255 | } |
| 256 | const get = (options, callback) => { |
| 257 | if (isQuanX) { |
| 258 | if (typeof options == "string") options = { url: options } |
| 259 | options["method"] = "GET" |
| 260 | $task.fetch(options).then(response => { |
| 261 | callback(null, adapterStatus(response), response.body) |
| 262 | }, reason => callback(reason.error, null, null)) |
| 263 | } |
| 264 | if (isSurge) $httpClient.get(options, (error, response, body) => { |
| 265 | callback(error, adapterStatus(response), body) |
| 266 | }) |
| 267 | if (node) { |
| 268 | node.request(options, (error, response, body) => { |
| 269 | callback(error, adapterStatus(response), body) |
| 270 | }) |
| 271 | } |
| 272 | } |
| 273 | const post = (options, callback) => { |
| 274 | if (isQuanX) { |
| 275 | if (typeof options == "string") options = { url: options } |
nothing calls this directly
no test coverage detected