added guard for firebase-config init call without creentials set

This commit is contained in:
Peter Svensson
2019-07-20 17:07:12 +02:00
parent 48df733c1a
commit e29eec83f8
3 changed files with 18 additions and 9 deletions

View File

@ -12,9 +12,15 @@ module.exports = function(RED) {
this.storage = c.storage
this.bucket = config.bucket || c.bucket
this.path = config.path
/*
console.log('configuring storage-write to listen for messages. config is')
console.dir(config)
console.log('storage is')
console.dir(this.storage)
*/
}
//console.log('configuring storage-write to listen for messages')
node.on('input', function(msg) {
if(msg && msg.payload){
let path = msg.payload.path || msg.path|| this.path