added guard for payload without path in rtdb-get and rtdb-on

This commit is contained in:
Peter Svensson
2019-07-21 12:54:19 +02:00
parent 87a2ed5022
commit 3ca32c00ae
3 changed files with 3 additions and 3 deletions

View File

@ -52,7 +52,7 @@ module.exports = function(RED) {
node.on('input', function(msg) {
let path = this.path
if(msg && msg.payload){
path = msg.payload.path
path = path || msg.payload.path
msgin = msg
setUpListener(path)
}

View File

@ -54,7 +54,7 @@ module.exports = function(RED) {
node.on('input', function(msg) {
let path = this.path
if(msg && msg.payload){
path = msg.payload.path
path = path || msg.payload.path
msgin = msg
setUpListener(path)
}