From 390991123a566aba8b8c380b952c4e65c009396f Mon Sep 17 00:00:00 2001 From: si458 Date: Fri, 6 Sep 2024 11:00:41 +0100 Subject: [PATCH] fix pluginhandler http protocol #6362 Signed-off-by: si458 --- pluginHandler.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pluginHandler.js b/pluginHandler.js index 6843c803..9eeeae57 100644 --- a/pluginHandler.js +++ b/pluginHandler.js @@ -364,7 +364,7 @@ module.exports.pluginHandler = function (parent) { if (force_url != null) dl_url = force_url; var url = require('url'); var q = url.parse(dl_url, true); - var http = (q.protocol == "http") ? require('http') : require('https'); + var http = (q.protocol == "http:") ? require('http') : require('https'); var opts = { path: q.pathname, host: q.hostname, @@ -457,7 +457,7 @@ module.exports.pluginHandler = function (parent) { if (plugin.versionHistoryUrl == null) reject("No version history available for this plugin."); var url = require('url'); var q = url.parse(plugin.versionHistoryUrl, true); - var http = (q.protocol == 'http') ? require('http') : require('https'); + var http = (q.protocol == 'http:') ? require('http') : require('https'); var opts = { path: q.pathname, host: q.hostname,