Skip to content

Commit

Permalink
Fix compiling of negated regex-based to= domain
Browse files Browse the repository at this point in the history
  • Loading branch information
gorhill committed Apr 19, 2023
1 parent 899c399 commit 3dddf4c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/js/static-net-filtering.js
Original file line number Diff line number Diff line change
Expand Up @@ -1500,7 +1500,7 @@ const compileDomainOpt = (ctors, iterable, prepend, units) => {
if ( len <= beg ) { continue; }
if ( s.charCodeAt(beg) === 0x2F /* / */ ) {
if ( beg === 0 ) { regexHits.push(s); continue; }
regexMisses.push(s); continue;
regexMisses.push(s.slice(1)); continue;
}
if ( s.endsWith('.*') === false ) {
if ( beg === 0 ) { hostnameHits.push(s); continue; }
Expand Down

0 comments on commit 3dddf4c

Please sign in to comment.