diff --git a/nodes/core/storage/66-mongodb.js b/nodes/core/storage/66-mongodb.js index ee14b90e7..12b30a7b5 100644 --- a/nodes/core/storage/66-mongodb.js +++ b/nodes/core/storage/66-mongodb.js @@ -27,8 +27,8 @@ module.exports = function(RED) { this.name = n.name; var url = "mongodb://"; - if (this.credentials && this.credentials.username && this.credentials.password) { - url += this.credentials.username+":"+this.credentials.password+"@"; + if (this.credentials && this.credentials.user && this.credentials.password) { + url += this.credentials.user+":"+this.credentials.password+"@"; } url += this.hostname+":"+this.port+"/"+this.db;