diff --git a/public/red/ui/editor.js b/public/red/ui/editor.js index 8fcf1aaf0..4a6f39e98 100644 --- a/public/red/ui/editor.js +++ b/public/red/ui/editor.js @@ -102,7 +102,8 @@ RED.editor = function() { if (!value || value == "_ADD_") { valid = false; } else { - valid = RED.nodes.node(value).valid; + var v = RED.nodes.node(value).valid; + valid = (v==null || v); } } return valid; @@ -214,10 +215,10 @@ RED.editor = function() { var removedLinks = updateNodeProperties(editing_node); if (changed) { + editing_node.changed = true; RED.view.dirty(true); RED.history.push({t:'edit',node:editing_node,changes:changes,links:removedLinks,dirty:wasDirty}); } - editing_node.changed = true; editing_node.dirty = true; validateNode(editing_node); RED.view.redraw();