Skip to content

Commit 772a891

Browse files
Rurik19Simounet
authored andcommitted
change regexp for isServicePage
1 parent 24142e7 commit 772a891

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

wallabagger/js/background.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -491,10 +491,7 @@ const saveExistFlag = (url, exists) => {
491491
existCache.set(url, exists);
492492
};
493493

494-
const isServicePage = (url) => {
495-
return RegExp('^(?!http(s?):(.*))').test(url) ||
496-
RegExp('^' + api.data.Url + '(.*)').test(url);
497-
};
494+
const isServicePage = (url) => !/^https?:\/\/.+/.test(url) || RegExp('^' + api.data.Url).test(url);
498495

499496
const addToAllTags = (tags) => {
500497
if (tags.length === 0) { return; }

0 commit comments

Comments
 (0)