Fix broken `redirect-rule=` priority parser

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

Regression from:
- cf2c638d8e
This commit is contained in:
Raymond Hill 2020-12-07 10:49:05 -05:00
parent ff5390f3a0
commit 5d7a5a559d
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2
1 changed files with 1 additions and 1 deletions

View File

@ -1169,8 +1169,8 @@ const Parser = class {
if ( asDataURI ) { token = token.slice(1); } if ( asDataURI ) { token = token.slice(1); }
const match = /:-?\d+$/.exec(token); const match = /:-?\d+$/.exec(token);
if ( match !== null ) { if ( match !== null ) {
token = token.slice(0, match.index);
priority = parseInt(token.slice(match.index + 1), 10); priority = parseInt(token.slice(match.index + 1), 10);
token = token.slice(0, match.index);
} }
return { token, priority, asDataURI }; return { token, priority, asDataURI };
} }