mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
Handle missing wires prop and string x/y props on import
This commit is contained in:
parent
bfd98f3767
commit
e6e7747ae1
@ -955,11 +955,11 @@ RED.nodes = (function() {
|
|||||||
def = registry.getNodeType(n.type);
|
def = registry.getNodeType(n.type);
|
||||||
if (!def || def.category != "config") {
|
if (!def || def.category != "config") {
|
||||||
var node = {
|
var node = {
|
||||||
x:n.x,
|
x:parseFloat(n.x || 0),
|
||||||
y:n.y,
|
y:parseFloat(n.y || 0),
|
||||||
z:n.z,
|
z:n.z,
|
||||||
type:0,
|
type:0,
|
||||||
wires:n.wires,
|
wires:n.wires||[],
|
||||||
inputLabels: n.inputLabels,
|
inputLabels: n.inputLabels,
|
||||||
outputLabels: n.outputLabels,
|
outputLabels: n.outputLabels,
|
||||||
icon: n.icon,
|
icon: n.icon,
|
||||||
|
Loading…
Reference in New Issue
Block a user