Fix skooma.js syntax for strict mode
This commit is contained in:
parent
b789242c4c
commit
bc251001bc
1 changed files with 2 additions and 1 deletions
|
@ -9,7 +9,7 @@ const parseAttribute = (attribute) => {
|
||||||
|
|
||||||
const parseArgs = (element, args) => {
|
const parseArgs = (element, args) => {
|
||||||
if (element.content) element = element.content
|
if (element.content) element = element.content
|
||||||
for (arg of args)
|
for (let arg of args)
|
||||||
if (typeof(arg) == "string")
|
if (typeof(arg) == "string")
|
||||||
element.appendChild(document.createTextNode(arg))
|
element.appendChild(document.createTextNode(arg))
|
||||||
else if ("nodeName" in arg)
|
else if ("nodeName" in arg)
|
||||||
|
@ -22,6 +22,7 @@ const parseArgs = (element, args) => {
|
||||||
}
|
}
|
||||||
|
|
||||||
const node = (name, args, xmlns) => {
|
const node = (name, args, xmlns) => {
|
||||||
|
let element
|
||||||
if (xmlns)
|
if (xmlns)
|
||||||
element = document.createElementNS(xmlns, name.replace("_", "-"))
|
element = document.createElementNS(xmlns, name.replace("_", "-"))
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in a new issue