aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorJohannes Zellner <johannes@cloudron.io>2019-02-23 23:23:42 +0100
committerJohannes Zellner <johannes@cloudron.io>2019-02-23 23:23:42 +0100
commit8dc61bb6fc5c3287aeec7ceeecace6ca63066269 (patch)
tree49488e2207b0ed1f8dbc22d02a429c616b11bae4 /src
parent47ba3ae4ff8e5a49b06de5bfea908bf6a0c599d6 (diff)
downloadSurfer-8dc61bb6fc5c3287aeec7ceeecace6ca63066269.tar.gz
Surfer-8dc61bb6fc5c3287aeec7ceeecace6ca63066269.tar.zst
Surfer-8dc61bb6fc5c3287aeec7ceeecace6ca63066269.zip
error is not defined here
Diffstat (limited to 'src')
-rw-r--r--src/auth.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/auth.js b/src/auth.js
index e148fb7..80fa122 100644
--- a/src/auth.js
+++ b/src/auth.js
@@ -96,7 +96,7 @@ function verifyUser(username, password, callback) {
96 result.on('searchEntry', function(entry) { items.push(entry.object); }); 96 result.on('searchEntry', function(entry) { items.push(entry.object); });
97 result.on('error', callback); 97 result.on('error', callback);
98 result.on('end', function (result) { 98 result.on('end', function (result) {
99 if (result.status !== 0 || items.length === 0) return callback(error); 99 if (result.status !== 0 || items.length === 0) return callback('Invalid credentials');
100 100
101 // pick the first found 101 // pick the first found
102 var user = items[0]; 102 var user = items[0];