mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
HttpRequest: unable to overide url with https url
This commit is contained in:
parent
ae13db90a9
commit
dc0d62cb28
@ -79,7 +79,9 @@ function HTTPRequest(n) {
|
|||||||
var httplib = (/^https/.test(url))?https:http;
|
var httplib = (/^https/.test(url))?https:http;
|
||||||
var node = this;
|
var node = this;
|
||||||
this.on("input",function(msg) {
|
this.on("input",function(msg) {
|
||||||
|
if (msg.url) {
|
||||||
|
httplib = (/^https/.test(msg.url))?https:http;
|
||||||
|
}
|
||||||
var opts = urllib.parse(msg.url||url);
|
var opts = urllib.parse(msg.url||url);
|
||||||
opts.method = (msg.method||method).toUpperCase();
|
opts.method = (msg.method||method).toUpperCase();
|
||||||
if (msg.headers) {
|
if (msg.headers) {
|
||||||
|
Loading…
Reference in New Issue
Block a user