mirror of
https://codeberg.org/nobody/LocalCDN.git
synced 2025-06-05 21:49:31 +02:00
Logic moved (#1085)
This commit is contained in:
@@ -1172,6 +1172,14 @@ mappings.cdn['cdn.bootcdn.net'] = mappings.cdn['cdnjs.cloudflare.com'];
|
|||||||
// CDN for the "Block Google Fonts" option (see: https://codeberg.org/nobody/LocalCDN/issues/269)
|
// CDN for the "Block Google Fonts" option (see: https://codeberg.org/nobody/LocalCDN/issues/269)
|
||||||
mappings.cdn['fonts.gstatic.com'] = mappings.cdn['fonts.googleapis.com'];
|
mappings.cdn['fonts.gstatic.com'] = mappings.cdn['fonts.googleapis.com'];
|
||||||
|
|
||||||
|
|
||||||
|
// Remove Google Fonts Endpoints for Chromium browsers (https://codeberg.org/nobody/LocalCDN/issues/1085)
|
||||||
|
if (!BrowserType.FIREFOX) {
|
||||||
|
delete mappings.cdn['fonts.gstatic.com'];
|
||||||
|
delete mappings.cdn['fonts.googleapis.com'];
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* List of CNAME CDNs
|
* List of CNAME CDNs
|
||||||
* https://codeberg.org/nobody/LocalCDN/issues/816
|
* https://codeberg.org/nobody/LocalCDN/issues/816
|
||||||
|
@@ -294,9 +294,6 @@ stateManager.logging = false;
|
|||||||
|
|
||||||
for (let mapping in mappings.cdn) {
|
for (let mapping in mappings.cdn) {
|
||||||
let supportedHost = Address.ANY_PROTOCOL + mapping + Address.ANY_PATH;
|
let supportedHost = Address.ANY_PROTOCOL + mapping + Address.ANY_PATH;
|
||||||
if (!BrowserType.FIREFOX && (mapping === 'fonts.gstatic.com' || mapping === 'fonts.googleapis.com')) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
stateManager.validHosts.push(supportedHost);
|
stateManager.validHosts.push(supportedHost);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user