From 1a002b6584d64fce5ca2666c5ed077f1f5785fe4 Mon Sep 17 00:00:00 2001 From: dakkar Date: Thu, 30 Dec 2021 16:27:37 +0000 Subject: template: undef attrs are removed --- resources/index.html | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/resources/index.html b/resources/index.html index 6711048..ef601f6 100644 --- a/resources/index.html +++ b/resources/index.html @@ -24,7 +24,9 @@ const name=attrs[i].name.replace('slot:',''); const valueKey=attrs[i].value; e.removeAttribute(attrs[i].name); - e.setAttribute(name,values[valueKey]); + if (values.hasOwnProperty(valueKey)) { + e.setAttribute(name,values[valueKey]); + } } } }, -- cgit v1.2.3