Add files via upload

This commit is contained in:
erosman 2023-11-10 12:06:20 +03:30 committed by GitHub
parent d93455ce38
commit 8307d4a35a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 3 deletions

View File

@ -9,7 +9,7 @@ typeof globalThis.browser === 'undefined' && (globalThis.browser = globalThis.ch
!browser.action && (browser.action = browser.browserAction);
// ---------- Default Preferences --------------------------
export let pref = {
export const pref = {
mode: 'disable',
sync: false,
proxyDNS: true,

View File

@ -11,7 +11,7 @@ class ProcessPref {
}
static async init() {
let pref = await browser.storage.local.get();
const pref = await browser.storage.local.get();
// storage sync -> local update
await Sync.get(pref);

View File

@ -17,7 +17,7 @@ export class Pattern {
// convert wildcard to regex string
static convertWildcard(str) {
if (str === '*') { return '\S+'; }
if (str === '*') { return '\\S+'; }
// escape regular expression special characters, minus * ?
return str.replace(/[.+^${}()|[\]\\]/g, '\\$&')