mirror of
https://github.com/gorhill/uBlock.git
synced 2024-10-04 08:37:11 +02:00
this fixes #1341
This commit is contained in:
parent
062eed9413
commit
a89f908a16
@ -192,6 +192,14 @@ uDom.nodeFromId('why').textContent = details.fs;
|
|||||||
return li;
|
return li;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
var safeDecodeURIComponent = function(s) {
|
||||||
|
try {
|
||||||
|
s = decodeURIComponent(s);
|
||||||
|
} catch (ex) {
|
||||||
|
}
|
||||||
|
return s;
|
||||||
|
};
|
||||||
|
|
||||||
var renderParams = function(parentNode, rawURL) {
|
var renderParams = function(parentNode, rawURL) {
|
||||||
var a = document.createElement('a');
|
var a = document.createElement('a');
|
||||||
a.href = rawURL;
|
a.href = rawURL;
|
||||||
@ -214,8 +222,8 @@ uDom.nodeFromId('why').textContent = details.fs;
|
|||||||
if ( pos === -1 ) {
|
if ( pos === -1 ) {
|
||||||
pos = param.length;
|
pos = param.length;
|
||||||
}
|
}
|
||||||
name = decodeURIComponent(param.slice(0, pos));
|
name = safeDecodeURIComponent(param.slice(0, pos));
|
||||||
value = decodeURIComponent(param.slice(pos + 1));
|
value = safeDecodeURIComponent(param.slice(pos + 1));
|
||||||
li = liFromParam(name, value);
|
li = liFromParam(name, value);
|
||||||
if ( reURL.test(value) ) {
|
if ( reURL.test(value) ) {
|
||||||
ul = document.createElement('ul');
|
ul = document.createElement('ul');
|
||||||
|
Loading…
Reference in New Issue
Block a user