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

Support array references in Debug property field

This commit is contained in:
Nick O'Leary 2016-06-20 10:19:18 +01:00
parent 77b13ce9d4
commit 343588b2a0
2 changed files with 8 additions and 5 deletions

View File

@ -1,3 +1,9 @@
#### xxx: unreleased
Fixes
- Support array references in Debug property field
#### 0.14.1: Maintenance Release #### 0.14.1: Maintenance Release
Fixes Fixes

View File

@ -50,12 +50,9 @@ module.exports = function(RED) {
var output = msg[property]; var output = msg[property];
if (this.complete !== "false" && typeof this.complete !== "undefined") { if (this.complete !== "false" && typeof this.complete !== "undefined") {
property = this.complete; property = this.complete;
var propertyParts = property.split(".");
try { try {
output = propertyParts.reduce(function (obj, i) { output = RED.util.getMessageProperty(msg,this.complete);
return obj[i]; } catch(err) {
}, msg);
} catch (err) {
output = undefined; output = undefined;
} }
} }