mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-05 08:17:47 +02:00
[feature/request-class] Convert any direct access to $_* to use $request
PHPBB3-9716
This commit is contained in:
@@ -610,6 +610,7 @@ class custom_profile
|
||||
function get_var($field_validation, &$profile_row, $default_value, $preview)
|
||||
{
|
||||
global $user;
|
||||
global $request;
|
||||
|
||||
$profile_row['field_ident'] = (isset($profile_row['var_name'])) ? $profile_row['var_name'] : 'pf_' . $profile_row['field_ident'];
|
||||
$user_ident = $profile_row['field_ident'];
|
||||
@@ -622,7 +623,7 @@ class custom_profile
|
||||
{
|
||||
if (isset($_REQUEST[$profile_row['field_ident']]))
|
||||
{
|
||||
$value = ($_REQUEST[$profile_row['field_ident']] === '') ? NULL : request_var($profile_row['field_ident'], $default_value);
|
||||
$value = ($request->variable($profile_row['field_ident'], '') === '') ? NULL : $request->variable($profile_row['field_ident'], $default_value);
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -894,6 +895,7 @@ class custom_profile
|
||||
{
|
||||
global $phpbb_root_path, $phpEx;
|
||||
global $config;
|
||||
global $request;
|
||||
|
||||
$var_name = 'pf_' . $profile_row['field_ident'];
|
||||
|
||||
@@ -938,7 +940,7 @@ class custom_profile
|
||||
break;
|
||||
|
||||
case FIELD_INT:
|
||||
if (isset($_REQUEST[$var_name]) && $_REQUEST[$var_name] === '')
|
||||
if (isset($_REQUEST[$var_name]) && $request->variable($var_name, '') === '')
|
||||
{
|
||||
$var = NULL;
|
||||
}
|
||||
|
Reference in New Issue
Block a user