1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Make defaults into strings rather than boolean.

Fixes #350
This commit is contained in:
Dave C-J 2014-08-25 15:09:52 +01:00
parent ecbf4add6b
commit 40c87ab14c

View File

@ -51,9 +51,9 @@
category: 'output', category: 'output',
defaults: { defaults: {
name: {value:""}, name: {value:""},
active: {value:true}, active: {value:"true"},
console: {value:false}, console: {value:"false"},
complete: {value:false} complete: {value:"false"}
}, },
label: function() { label: function() {
return this.name||"debug"; return this.name||"debug";
@ -115,14 +115,14 @@
var sbc = document.getElementById("debug-content"); var sbc = document.getElementById("debug-content");
var messageCount = 0; var messageCount = 0;
RED._debug = function(msg) { RED._debug = function(msg) {
handleDebugMessage("",{ handleDebugMessage("",{
name:"debug", name:"debug",
msg:msg msg:msg
}); });
} }
var handleDebugMessage = function(t,o) { var handleDebugMessage = function(t,o) {
var msg = document.createElement("div"); var msg = document.createElement("div");
msg.onmouseover = function() { msg.onmouseover = function() {
@ -148,7 +148,7 @@
if (node) { if (node) {
RED.view.showWorkspace(node.z); RED.view.showWorkspace(node.z);
} }
}; };
var name = (o.name?o.name:o.id).toString().replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;"); var name = (o.name?o.name:o.id).toString().replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;");
var topic = (o.topic||"").toString().replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;"); var topic = (o.topic||"").toString().replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;");