Ladybird: Don't prepend 'about:' urls with an http:// scheme

This commit is contained in:
Karol Kosek 2023-01-19 19:39:25 +01:00 committed by Linus Groh
parent 4f36893fda
commit 5e89773937
Notes: sideshowbarker 2024-07-17 01:30:14 +09:00

View file

@ -165,7 +165,7 @@ void Tab::focus_location_editor()
void Tab::navigate(QString url)
{
if (!url.startsWith("http://", Qt::CaseInsensitive) && !url.startsWith("https://", Qt::CaseInsensitive) && !url.startsWith("file://", Qt::CaseInsensitive))
if (!url.startsWith("http://", Qt::CaseInsensitive) && !url.startsWith("https://", Qt::CaseInsensitive) && !url.startsWith("file://", Qt::CaseInsensitive) && !url.startsWith("about:", Qt::CaseInsensitive))
url = "http://" + url;
view().load(ak_deprecated_string_from_qstring(url));
}