mirror of
https://github.com/jellyfin/jellyfin-web.git
synced 2024-11-18 03:18:19 -07:00
fix reloading plugin pages
This commit is contained in:
parent
5f9f5f3ccf
commit
37927a9a1a
@ -102,8 +102,16 @@ define([], function () {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function replaceAll(str, find, replace) {
|
||||||
|
|
||||||
|
return str.split(find).join(replace);
|
||||||
|
}
|
||||||
|
|
||||||
function parseHtml(html) {
|
function parseHtml(html) {
|
||||||
|
|
||||||
|
html = replaceAll(html, '<!--<script', '<script');
|
||||||
|
html = replaceAll(html, '</script>-->', '</script>');
|
||||||
|
|
||||||
var wrapper = document.createElement('div');
|
var wrapper = document.createElement('div');
|
||||||
wrapper.innerHTML = html;
|
wrapper.innerHTML = html;
|
||||||
return wrapper.querySelector('div[data-role="page"]');
|
return wrapper.querySelector('div[data-role="page"]');
|
||||||
|
Loading…
Reference in New Issue
Block a user