WebUI: Only prepend scheme when it is not present. Closes #8057.

This commit is contained in:
Chocobo1
2017-12-18 14:12:31 +08:00
committed by sledgehammer999
parent 13210b3e9f
commit c7d3d6ac90

View File

@@ -90,7 +90,9 @@ namespace
{
inline QUrl urlFromHostHeader(const QString &hostHeader)
{
return QUrl(QLatin1String("http://") + hostHeader);
if (!hostHeader.contains(QLatin1String("://")))
return QUrl(QLatin1String("http://") + hostHeader);
return hostHeader;
}
}