misc: Minor improvements (#1875)

* misc: Minor improvements

* Update activate.php

* Update admin_ug_auth.php

* Update admin_ug_auth.php

* Update register.php

* Update index.php

* Update admin_ug_auth.php
This commit is contained in:
Roman Kelesidis 2025-04-05 21:01:59 +07:00 committed by GitHub
commit 41a78ddbcb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 10 additions and 10 deletions

View file

@ -11,7 +11,7 @@ if (!defined('BB_ROOT')) {
die(basename(__FILE__));
}
if (empty($_GET['u']) || empty($_GET['act_key'])) {
if (empty($_GET[POST_USERS_URL]) || empty($_GET['act_key'])) {
bb_die('Bad request');
}

View file

@ -122,8 +122,8 @@ switch ($mode) {
];
// Select a profile: your own for the user, any for the admin
if (IS_ADMIN && !empty($_REQUEST['u'])) {
$pr_user_id = (int)$_REQUEST['u'];
if (IS_ADMIN && !empty($_REQUEST[POST_USERS_URL])) {
$pr_user_id = (int)$_REQUEST[POST_USERS_URL];
$adm_edit = ($pr_user_id != $userdata['user_id']);
} else {
$pr_user_id = $userdata['user_id'];