USO bug workaround: generalize getStyleURL()
This commit is contained in:
parent
fba85b36cc
commit
050109428c
|
@ -129,10 +129,11 @@ new MutationObserver((mutations, observer) => {
|
||||||
function getStyleURL () {
|
function getStyleURL () {
|
||||||
const url = getMeta('stylish-code-chrome');
|
const url = getMeta('stylish-code-chrome');
|
||||||
// TODO: remove when USO is fixed
|
// TODO: remove when USO is fixed
|
||||||
if (FIREFOX || OPERA || VIVALDI || CHROMIUM) {
|
const directUrl = getMeta('stylish-update-url');
|
||||||
|
if (directUrl.includes('?') && !url.includes('?')) {
|
||||||
/* get custom settings from the update url */
|
/* get custom settings from the update url */
|
||||||
return Object.assign(new URL(url), {
|
return Object.assign(new URL(url), {
|
||||||
search: (new URL(getMeta('stylish-update-url'))).search
|
search: (new URL(directUrl)).search
|
||||||
}).href;
|
}).href;
|
||||||
}
|
}
|
||||||
return url;
|
return url;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user