dnswarden / blocklist-staging

Staging blacklist/whitelist/customlist repo for dnswarden
MIT License
18 stars 4 forks source link

download.js: Improve the regex to be simpler and potentially more effective #56

Closed SpencerIsGiddy closed 1 year ago

SpencerIsGiddy commented 1 year ago

This pr simplifies the regex to be more concise.

SpencerIsGiddy commented 1 year ago

I can’t seem to figure out why the test is failing. The functionality remains the same and the only change seems the be how the regex are written.

bhanupratapys commented 1 year ago

Regex is failing. You should be able to get this result from this input

SpencerIsGiddy commented 1 year ago

I’m going to close this as I try to figure something out. Because nothing seems to be working my way today with regexes

il reopen this once I figure out a solution

bhanupratapys commented 1 year ago

I’m going to close this as I try to figure something out. Because nothing seems to be working my way today with regexes

il reopen this once I figure out a solution

Regex as of now is a 3 step process (firstReplace, secondReplace and domainMatch). Try to manipulate single step at a time and see whether it works or not.