diff --git a/config/config.default.php b/config/config.default.php index ef2c4ee7..b04688c7 100644 --- a/config/config.default.php +++ b/config/config.default.php @@ -17,7 +17,7 @@ return [ // Enable maintenance mode (show a static page) 'maintenance' => (bool)env('MAINTENANCE', false), - // Application name (not the event name!) + // Application name (not the event name) 'app_name' => env('APP_NAME', 'Engelsystem'), // Set to development to enable debugging messages diff --git a/includes/pages/admin_user.php b/includes/pages/admin_user.php index 5db38912..9f3c2f6b 100644 --- a/includes/pages/admin_user.php +++ b/includes/pages/admin_user.php @@ -135,7 +135,7 @@ function admin_user() } $angel_highest_group = DB::selectOne( - 'SELECT `group_id` FROM `UserGroups` WHERE `uid`=? ORDER BY `group_id` LIMIT 1', + 'SELECT group_id FROM `UserGroups` WHERE `uid`=? ORDER BY `group_id` DESC LIMIT 1', [$user_id] ); if (!empty($angel_highest_group)) { diff --git a/includes/pages/guest_login.php b/includes/pages/guest_login.php index e0f7f474..1898e599 100644 --- a/includes/pages/guest_login.php +++ b/includes/pages/guest_login.php @@ -299,7 +299,7 @@ function guest_register() } // Assign user-group and set password - Db::insert('INSERT INTO `UserGroups` (`uid`, `group_id`) VALUES (?, -20)', [$user->id]); + Db::insert('INSERT INTO `UserGroups` (`uid`, `group_id`) VALUES (?, 20)', [$user->id]); if ($enable_password) { auth()->setPassword($user, $request->postData('password')); }