mirror of
https://github.com/keepassxreboot/keepassxc-browser.git
synced 2026-03-11 08:54:43 +00:00
Fix iframe TLD matching
This commit is contained in:
parent
9dba813a5c
commit
eb9ba6522e
1 changed files with 1 additions and 1 deletions
|
|
@ -423,7 +423,7 @@ page.getBaseDomainFromUrl = async function(hostname, url) {
|
|||
}
|
||||
|
||||
// Remove the top level domain part from the hostname, e.g. https://another.example.co.uk -> https://another.example
|
||||
const finalDomain = hostname.slice(0, hostname.indexOf(tld) - 1);
|
||||
const finalDomain = hostname.slice(0, hostname.lastIndexOf(tld) - 1);
|
||||
// Split the URL and select the last part, e.g. https://another.example -> example
|
||||
let baseDomain = finalDomain.split('.')?.at(-1);
|
||||
// Append the top level domain back to the URL, e.g. example -> example.co.uk
|
||||
|
|
|
|||
Loading…
Reference in a new issue