Commit a382fbc1 authored by gizmo1-11's avatar gizmo1-11 Committed by yzx9
Browse files

changed variable "user1" to "user"

I used "user1", because Im not sure about the scope inside the anonymous callback functions
parent a107b644
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -186,7 +186,7 @@ const AuthenticationManager = {

  createIfNotExistAndLogin(
    query,
    user1,
    user,
    callback,
    uid,
    firstname,
@@ -194,7 +194,7 @@ const AuthenticationManager = {
    mail,
    isAdmin
  ) {
    if (!user1) {
    if (!user) {
      //console.log('Creating User:' + JSON.stringify(query))
      //create random pass for local userdb, does not get checked for ldap users during login
      let pass = require("crypto").randomBytes(32).toString("hex")
@@ -228,7 +228,7 @@ const AuthenticationManager = {
        }
      ) // end register user
    } else {
      AuthenticationManager.login(user1, "randomPass", callback)
      AuthenticationManager.login(user, "randomPass", callback)
    }
  },