mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-30 21:40:43 +02:00
[feature/avatars] Create setting for enabling avatar in manager
PHPBB3-10018
This commit is contained in:
@@ -201,4 +201,20 @@ class phpbb_avatar_manager
|
||||
|
||||
return $this->config["allow_avatar_{$config_name}"];
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the settings array for enabling/disabling an avatar driver
|
||||
*
|
||||
* @param string $driver Avatar driver object
|
||||
*
|
||||
* @return array Array of configuration options as consumed by acp_board
|
||||
*/
|
||||
public function get_avatar_settings($driver)
|
||||
{
|
||||
$config_name = preg_replace('#^phpbb_avatar_driver_#', '', get_class($driver));
|
||||
|
||||
return array(
|
||||
'allow_avatar_' . $config_name => array('lang' => 'ALLOW_' . strtoupper($config_name), 'validate' => 'bool', 'type' => 'radio:yes_no', 'explain' => false),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user