mirror of
https://github.com/zen-browser/desktop.git
synced 2025-09-05 19:08:18 +00:00
Fixed glance opening on non-http(s) or file links such as magnet links (closes https://github.com/zen-browser/desktop/issues/7173)
This commit is contained in:
@@ -497,6 +497,10 @@
|
||||
if (url1.startsWith('about:')) {
|
||||
return true;
|
||||
}
|
||||
// https://github.com/zen-browser/desktop/issues/7173: Only glance up links that are http(s) or file
|
||||
if (!url1.startsWith('http') && !url1.startsWith('https') && !url1.startsWith('file')) {
|
||||
return false;
|
||||
}
|
||||
return Services.io.newURI(url1).host !== url2.host;
|
||||
} catch (e) {
|
||||
return true;
|
||||
|
Reference in New Issue
Block a user