diff options
Diffstat (limited to 'common/patterns.js')
-rw-r--r-- | common/patterns.js | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/common/patterns.js b/common/patterns.js index 7d28dfe..0b1c3ad 100644 --- a/common/patterns.js +++ b/common/patterns.js @@ -72,9 +72,9 @@ function match_or_throw(regex, string, error_msg) function deconstruct_url(url, use_limits=true) { - const max = MAX; + const max = Object.assign({}, MAX); if (!use_limits) { - for (key in MAX) + for (const key in MAX) max[key] = Infinity; } @@ -129,6 +129,7 @@ function deconstruct_url(url, use_limits=true) return deco; } +#EXPORT deconstruct_url function* each_domain_pattern(deco) { @@ -183,10 +184,4 @@ function* each_url_pattern(url) yield `${deco.proto}://${domain}${path}`; } } - -/* - * EXPORTS_START - * EXPORT each_url_pattern - * EXPORT deconstruct_url - * EXPORTS_END - */ +#EXPORT each_url_pattern |