Change node can set msg property to another msg property. Closes #456

This commit is contained in:
Anna Thomas
2014-10-28 11:02:46 +00:00
parent bd75c1c753
commit ce6513e7f7
3 changed files with 403 additions and 283 deletions

View File

@@ -61,7 +61,9 @@
action: {value:"replace",required:true},
property: {value:"payload",required:true},
from: {value:"",validate: function(v) {
if (this.action == "change" && this.reg) {
if (this.action === "change" && !this.from) {
return false;
} else if (this.action === "change" && this.reg) {
try {
var re = new RegExp(this.from, "g");
return true;