Support redirect rules with no pattern

Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/977

No pattern will imply `*` for the redirect destination
part of the rule.
This commit is contained in:
Raymond Hill 2020-06-14 15:09:35 -04:00
parent 7e4b920bc7
commit cb5437b161
No known key found for this signature in database
GPG key ID: 25E1490B761470C2

View file

@ -529,7 +529,7 @@ RedirectEngine.prototype.compileRuleFromStaticFilter = function(line) {
/******************************************************************************/ /******************************************************************************/
RedirectEngine.prototype.reFilterParser = /^(?:\|\|([^\/:?#^]+)|\*)([^$]+)?\$([^$]+)$/; RedirectEngine.prototype.reFilterParser = /^(?:\|\|([^\/:?#^]+)|\*?)([^$]+)?\$([^$]+)$/;
RedirectEngine.prototype.supportedTypes = new Map([ RedirectEngine.prototype.supportedTypes = new Map([
[ 'css', 'stylesheet' ], [ 'css', 'stylesheet' ],