mirror of https://github.com/node-red/node-red.git
Prevent node z property getting set to 0 or ""
parent
e8e44f9a32
commit
dc26022fb4
|
@ -553,6 +553,9 @@ RED.nodes = (function() {
|
|||
node.id = n.id;
|
||||
node.type = n.type;
|
||||
node.z = n.z;
|
||||
if (node.z === 0 || node.z === "") {
|
||||
delete node.z;
|
||||
}
|
||||
if (n.d === true) {
|
||||
node.d = true;
|
||||
}
|
||||
|
@ -1351,6 +1354,9 @@ RED.nodes = (function() {
|
|||
users:[],
|
||||
_config:{}
|
||||
};
|
||||
if (!n.z) {
|
||||
delete configNode.z;
|
||||
}
|
||||
if (n.hasOwnProperty('d')) {
|
||||
configNode.d = n.d;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue