Properly escape node types in palette

We were only escaping the first instance of any invalid dom char
and not all of the
This commit is contained in:
Nick O'Leary 2019-06-28 22:39:27 +01:00
parent b73f12cdba
commit 55645e3730
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9
1 changed files with 1 additions and 1 deletions

View File

@ -150,7 +150,7 @@ RED.palette = (function() {
}
function escapeNodeType(nt) {
return nt.replace(" ","_").replace(".","_").replace(":","_");
return nt.replace(/[ .:]/g,"_");
}
function addNodeType(nt,def) {