mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-27 21:58:52 +00:00
[ticket/12159] Fix codesniffer complaints due to profilefields and passwords
The two PRs regarding profilefields and passwords manager that were recently merged caused a few codesniffer complaints that are fixed by these changes. PHPBB3-12159
This commit is contained in:
parent
ad2d1fcbcb
commit
6f92996d98
5 changed files with 3 additions and 5 deletions
|
@ -27,7 +27,7 @@ class ucp_remind
|
||||||
function main($id, $mode)
|
function main($id, $mode)
|
||||||
{
|
{
|
||||||
global $config, $phpbb_root_path, $phpEx;
|
global $config, $phpbb_root_path, $phpEx;
|
||||||
global $db, $user, $auth, $template, $phpbb_container;;
|
global $db, $user, $auth, $template, $phpbb_container;
|
||||||
|
|
||||||
if (!$config['allow_password_reset'])
|
if (!$config['allow_password_reset'])
|
||||||
{
|
{
|
||||||
|
|
|
@ -313,7 +313,7 @@ class manager
|
||||||
$profile_field = $this->type_collection[$ident_ary['data']['field_type']];
|
$profile_field = $this->type_collection[$ident_ary['data']['field_type']];
|
||||||
$value = $profile_field->get_profile_value($ident_ary['value'], $ident_ary['data']);
|
$value = $profile_field->get_profile_value($ident_ary['value'], $ident_ary['data']);
|
||||||
|
|
||||||
if ($value === NULL)
|
if ($value === null)
|
||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
|
@ -327,7 +327,6 @@ class type_date extends type_base
|
||||||
return $current_value;
|
return $current_value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
return parent::get_excluded_options($key, $action, $current_value, $field_data, $step);
|
return parent::get_excluded_options($key, $action, $current_value, $field_data, $step);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -273,7 +273,6 @@ class type_dropdown extends type_base
|
||||||
return sizeof(explode("\n", $this->request->variable('lang_options', '', true)));
|
return sizeof(explode("\n", $this->request->variable('lang_options', '', true)));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
return parent::get_excluded_options($key, $action, $current_value, $field_data, $step);
|
return parent::get_excluded_options($key, $action, $current_value, $field_data, $step);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -87,7 +87,7 @@ class type_int extends type_base
|
||||||
*/
|
*/
|
||||||
public function get_default_field_value($field_data)
|
public function get_default_field_value($field_data)
|
||||||
{
|
{
|
||||||
if ($field_data['field_default_value'] === '')
|
if ($field_data['field_default_value'] === '')
|
||||||
{
|
{
|
||||||
// We cannot insert an empty string into an integer column.
|
// We cannot insert an empty string into an integer column.
|
||||||
return null;
|
return null;
|
||||||
|
|
Loading…
Add table
Reference in a new issue