From 1a5a548fbf5fd8e53cc4355681ec1c0f640714fe Mon Sep 17 00:00:00 2001 From: Nick O'Leary Date: Mon, 8 Sep 2014 19:24:06 +0100 Subject: [PATCH] Incorrect credentials in mongo node Closes #386 --- nodes/core/storage/66-mongodb.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) 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;