mirror of
				https://github.com/node-red/node-red.git
				synced 2025-03-01 10:36:34 +00:00 
			
		
		
		
	Import fails on nodes with config labels
This commit is contained in:
		@@ -42,7 +42,8 @@
 | 
			
		||||
        outputs:1,
 | 
			
		||||
        icon: "serial.png",
 | 
			
		||||
        label: function() {
 | 
			
		||||
            return this.name||(this.serial)?RED.nodes.node(this.serial).label():"serial";
 | 
			
		||||
            var serialNode = RED.nodes.node(this.serial);
 | 
			
		||||
            return this.name||(serialNode?serialNode.label():"serial");
 | 
			
		||||
        },
 | 
			
		||||
        labelStyle: function() {
 | 
			
		||||
            return this.name?"node_label_italic":"";
 | 
			
		||||
@@ -80,7 +81,8 @@
 | 
			
		||||
        icon: "serial.png",
 | 
			
		||||
        align: "right",
 | 
			
		||||
        label: function() {
 | 
			
		||||
            return this.name||((this.serial)?RED.nodes.node(this.serial).label():"serial");
 | 
			
		||||
            var serialNode = RED.nodes.node(this.serial);
 | 
			
		||||
            return this.name||(serialNode?serialNode.label():"serial");
 | 
			
		||||
        },
 | 
			
		||||
        labelStyle: function() {
 | 
			
		||||
            return this.name?"node_label_italic":"";
 | 
			
		||||
 
 | 
			
		||||
@@ -42,7 +42,8 @@
 | 
			
		||||
        outputs:1,
 | 
			
		||||
        icon: "hash.png",
 | 
			
		||||
        label: function() {
 | 
			
		||||
            return this.name||(this.ircserver)?RED.nodes.node(this.ircserver).label():"irc";
 | 
			
		||||
            var ircNode = RED.nodes.node(this.ircserver);
 | 
			
		||||
            return this.name||((ircNode?ircNode.label():"irc");
 | 
			
		||||
        },
 | 
			
		||||
        labelStyle: function() {
 | 
			
		||||
            return this.name?"node_label_italic":"";
 | 
			
		||||
 
 | 
			
		||||
@@ -86,7 +86,8 @@
 | 
			
		||||
        icon: "mongodb.png",
 | 
			
		||||
        align: "right",
 | 
			
		||||
        label: function() {
 | 
			
		||||
            return this.name||((this.mongodb)?RED.nodes.node(this.mongodb).label()+"//"+this.collection:"mongodb");
 | 
			
		||||
            var mongoNode = RED.nodes.node(this.mongodb);
 | 
			
		||||
            return this.name||this.collection||(mongoNode?mongoNode.label():"mongodb");
 | 
			
		||||
        },
 | 
			
		||||
        labelStyle: function() {
 | 
			
		||||
            return this.name?"node_label_italic":"";
 | 
			
		||||
@@ -129,7 +130,8 @@
 | 
			
		||||
        outputs:1,
 | 
			
		||||
        icon: "mongodb.png",
 | 
			
		||||
        label: function() {
 | 
			
		||||
            return this.name||((this.mongodb)?RED.nodes.node(this.mongodb).label()+"//"+this.collection:"mongodb");
 | 
			
		||||
            var mongoNode = RED.nodes.node(this.mongodb);
 | 
			
		||||
            return this.name||(mongoNode?mongoNode.label()+"//"+this.collection:"mongodb");
 | 
			
		||||
        },
 | 
			
		||||
        labelStyle: function() {
 | 
			
		||||
            return this.name?"node_label_italic":"";
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user