Closed geoffreyvanwyk closed 5 years ago
Thanks Geoffrey for sharing this fix! Just wondering. Would it be cleaner and more consistent to explicitly set the value in the constructor (like all existing authentication plugins do)? The class property is already declared in the base class and it feels a bit counter-intuitive to re-declare and re-initialize it in the subclass this way.
We could have a default constructor like this in the auth.mustache
file:
/**
* Constructor.
*/
public function __construct() {
$this->authtype = '{{ component_name }}';
$this->config = get_config('{{ component }}');
}
@mudrd8mz, I will update the pull request.
Thanks, merged.
This commit adds the public $authtype attribute to the authplugin<name> class which is used to obtain the plugin name on the "Manage Authentication" page. Otherwise, only [[pluginname]] is shown in the "Name" column of the plugins table.