Merge pull request #2207 from keepassxreboot/fix/ignore_all_ports_by_default

Ignore all ports by default in Site Preferences
This commit is contained in:
Sami Vänttinen 2024-05-28 07:47:11 +03:00 committed by GitHub
commit 72832c1a5b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -87,8 +87,8 @@ const siteMatch = function(site, url) {
const siteUrl = new URL(site);
const currentUrl = new URL(url);
// Match scheme and port
if (siteUrl.protocol !== currentUrl.protocol || siteUrl.port !== currentUrl.port) {
// Match scheme and port. If Site Preferences does not use a port, all ports are ignored.
if (siteUrl.protocol !== currentUrl.protocol || (siteUrl.port && siteUrl.port !== currentUrl.port)) {
return false;
}