mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Removed unused variables and updated coding style
This commit is contained in:
@@ -41,33 +41,36 @@ function authenticate($username, $password) {
|
||||
|
||||
return $user_authenticated;
|
||||
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
// group membership is not required and user is valid
|
||||
return 1;
|
||||
};
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
return 0;
|
||||
}
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
echo ldap_error($ds);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
function reauthenticate($sess_id, $token) {
|
||||
function reauthenticate() {
|
||||
// not supported so return 0
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
function passwordscanchange($username='') {
|
||||
function passwordscanchange() {
|
||||
// not supported so return 0
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
function changepassword($username, $newpassword) {
|
||||
function changepassword() {
|
||||
// not supported so return 0
|
||||
return 0;
|
||||
}
|
||||
@@ -79,7 +82,7 @@ function auth_usermanagement() {
|
||||
}
|
||||
|
||||
|
||||
function adduser($username, $password, $level, $email='', $realname='', $can_modify_passwd='1') {
|
||||
function adduser() {
|
||||
// not supported so return 0
|
||||
return 0;
|
||||
}
|
||||
@@ -219,7 +222,8 @@ function get_fullname($username) {
|
||||
$entries = ldap_get_entries($ds, $result);
|
||||
if ($entries['count'] > 0) {
|
||||
$membername = $entries[0]['name'][0];
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
$membername = $username;
|
||||
}
|
||||
|
||||
@@ -263,7 +267,8 @@ function get_dn($samaccountname) {
|
||||
$entries = ldap_get_entries($ds, $result);
|
||||
if ($entries['count'] > 0) {
|
||||
return $entries[0]['dn'];
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
return '';
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user