MCPcopy Create free account
hub / github.com/scriptscat/scriptcat / toUniquePatternStrings

Function toUniquePatternStrings

src/pkg/utils/url_matcher.ts:233–235  ·  view source on GitHub ↗
(x: URLRuleEntry[])

Source from the content-addressed store, hash-verified

231};
232
233export const toUniquePatternStrings = (x: URLRuleEntry[]) => {
234 return [...new Set<string>(x.map((e: URLRuleEntry) => e.patternString))];
235};
236
237const urlMatchCache = new Map<string, boolean>();
238export const isUrlMatch = (url: string, rule: URLRuleEntry) => {

Callers 2

getUserScriptRegisterFunction · 0.90
getApiMatchesAndGlobsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected