Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[Plugin Installer] Only force http icon protocol for http-based repos…
…itories. Fixes #31783
  • Loading branch information
borysiasty committed Sep 16, 2019
1 parent 6c03a5b commit be4c5f0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion python/pyplugin_installer/installer_data.py
Expand Up @@ -407,7 +407,9 @@ def xmlDownloaded(self):
trusted = True
icon = pluginNodes.item(i).firstChildElement("icon").text().strip()
if icon and not icon.startswith("http"):
icon = "http://{}/{}".format(QUrl(self.mRepositories[reposName]["url"]).host(), icon)
url = QUrl(self.mRepositories[reposName]["url"])
if url.scheme() in ('http', 'https'):
icon = "{}://{}/{}".format(url.scheme(), url.host(), icon)

if pluginNodes.item(i).toElement().hasAttribute("plugin_id"):
plugin_id = pluginNodes.item(i).toElement().attribute("plugin_id")
Expand Down

0 comments on commit be4c5f0

Please sign in to comment.