public function getUserInfo($username, $password = null) { $user = $this->_ldap->search()->where('samaccountname', '=', $username)->first(); if (!$user) { return; } return $this->mapDataToUserModel($user, $password); }