Fix unescaped curly braces in javascript formatting

This would previously throw an error due to `format` interpreting the
curly braces as placeholders
This commit is contained in:
Sky Leite
2023-02-04 00:29:34 -03:00
parent 1edcc09020
commit 4e92d4bfc5
+9 -8
View File
@@ -261,18 +261,19 @@ class Tab:
wrappedjs = (
"""
function scriptFunc() {
function scriptFunc() {{
{js}
}
if (document.readyState === 'loading') {
addEventListener('DOMContentLoaded', () => {
}}
if (document.readyState === 'loading') {{
addEventListener('DOMContentLoaded', () => {{
scriptFunc();
});
} else {
}});
}} else {{
scriptFunc();
}
}}
""".format(
)
js=js
)
if add_dom_wrapper
else js
)