This repository was archived by the owner on Feb 20, 2021. It is now read-only.

Description
request.del() at
|
this._del('/hooks/' + id, {}, function (error, body) { |
throws this error:
error: {
"errno": "ECONNREFUSED",
"code": "ECONNREFUSED",
"syscall": "connect",
"address": "127.0.0.1",
"port": 80
}
When I replace the request.del() call with this HTTP.call() deletion works:
const response = HTTP.call("DELETE", urlr,
{
query: "token=" + Meteor.settings.BC_TOKEN
})
if (response.statusCode === 204) {
console.log("webhook deleted successfully: ", response.statusCode)
return true
} else {
console.error("error when deleting webhook:", response.statusCode)
console.log("response.content:", response.content)
}
Please fix this.