Feat: url redirect module

This commit is contained in:
SukkaW
2023-10-01 02:31:27 +08:00
parent 2204dcd2c7
commit 243653a823
4 changed files with 106 additions and 7 deletions

View File

@@ -10,12 +10,7 @@ const { compareAndWriteFile } = require('./lib/create-file');
const { getGorhillPublicSuffixPromise } = require('./lib/get-gorhill-publicsuffix');
const { createCachedGorhillGetDomain } = require('./lib/cached-tld-parse');
/**
* @param {string} string
*/
const escapeRegExp = (string) => {
return string.replaceAll(/[$()*+.?[\\\]^{|}]/g, '\\$&');
};
const escapeRegExp = (string = '') => string.replaceAll(/[$()*+.?[\\\]^{|}]/g, '\\$&');
const buildInternalCDNDomains = task(__filename, async () => {
const set = new Set();