1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

[feature/avatars] Let avatar manager handle $ignore_config

The avatar manager already handles if avatars are enabled. It should also
handle ignoring the config settings.

PHPBB3-10018
This commit is contained in:
Marc Alexander
2012-11-30 15:12:34 +01:00
parent 562ebe5c12
commit d5cbedaaa2
8 changed files with 35 additions and 69 deletions

View File

@@ -24,24 +24,13 @@ class phpbb_avatar_driver_remote extends phpbb_avatar_driver
/**
* @inheritdoc
*/
public function get_data($row, $ignore_config = false)
public function get_data($row)
{
if ($ignore_config || $this->config['allow_avatar_remote'])
{
return array(
'src' => $row['avatar'],
'width' => $row['avatar_width'],
'height' => $row['avatar_height'],
);
}
else
{
return array(
'src' => '',
'width' => 0,
'height' => 0,
);
}
return array(
'src' => $row['avatar'],
'width' => $row['avatar_width'],
'height' => $row['avatar_height'],
);
}
/**