diff options
Diffstat (limited to 'web/lib/acctfuncs.inc.php')
-rw-r--r-- | web/lib/acctfuncs.inc.php | 23 |
1 files changed, 1 insertions, 22 deletions
diff --git a/web/lib/acctfuncs.inc.php b/web/lib/acctfuncs.inc.php index e2e37b87..578c3764 100644 --- a/web/lib/acctfuncs.inc.php +++ b/web/lib/acctfuncs.inc.php @@ -117,7 +117,7 @@ function process_account_form($TYPE,$A,$U="",$T="",$S="",$E="", $error = __("Missing User ID"); } - if (!$error && !valid_username($U) && !user_is_privileged($editor_user)) { + if (!$error && !valid_username($U)) { $error = __("The username is invalid.") . "<ul>\n" ."<li>" . __("It must be between %s and %s characters long", USERNAME_MIN_LEN, USERNAME_MAX_LEN ) @@ -832,27 +832,6 @@ function user_delete($id) { } /** - * Determine if a user is either a Trusted User or Developer - * - * @param string $id The ID of the user to check if privileged - * - * @return int|string Return 0 if un-privileged, "2" if Trusted User, "3" if Developer - */ -function user_is_privileged($id) { - $dbh = DB::connect(); - $q = "SELECT AccountTypeID FROM Users WHERE ID = " . $id; - $result = $dbh->query($q); - if ($result) { - $row = $result->fetch(PDO::FETCH_NUM); - if($row[0] > 1) { - return $row[0]; - } - } - return 0; - -} - -/** * Remove the session from the database on logout * * @param string $sid User's session ID |