From 48b5d5e92851161ee3b3ebc7bf5b6ae6d1f0914d Mon Sep 17 00:00:00 2001 From: Andreas Gohr Date: Wed, 3 Dec 2014 16:50:16 +0100 Subject: warn about enabled, but not used auth plugins --- lib/plugins/extension/helper/list.php | 5 +++++ lib/plugins/extension/lang/en/lang.php | 1 + 2 files changed, 6 insertions(+) diff --git a/lib/plugins/extension/helper/list.php b/lib/plugins/extension/helper/list.php index 9b1988d84..f7e6eb2ca 100644 --- a/lib/plugins/extension/helper/list.php +++ b/lib/plugins/extension/helper/list.php @@ -461,6 +461,7 @@ class helper_plugin_extension_list extends DokuWiki_Plugin { * @return string The HTML code */ function make_actions(helper_plugin_extension_extension $extension) { + global $conf; $return = ''; $errors = ''; @@ -492,6 +493,10 @@ class helper_plugin_extension_list extends DokuWiki_Plugin { $errors .= '

'.$this->getLang('git').'

'; } + if ($extension->isEnabled() && in_array('Auth', $extension->getTypes()) && $conf['auth'] != $extension->getID()) { + $errors .= '

'.$this->getLang('auth').'

'; + } + }else{ if (($canmod = $extension->canModify()) === true) { if ($extension->getDownloadURL()) { diff --git a/lib/plugins/extension/lang/en/lang.php b/lib/plugins/extension/lang/en/lang.php index 72c9b9e2d..fc8860c5d 100644 --- a/lib/plugins/extension/lang/en/lang.php +++ b/lib/plugins/extension/lang/en/lang.php @@ -94,6 +94,7 @@ $lang['noperms'] = 'Extension directory is not writable'; $lang['notplperms'] = 'Template directory is not writable'; $lang['nopluginperms'] = 'Plugin directory is not writable'; $lang['git'] = 'This extension was installed via git, you may not want to update it here.'; +$lang['auth'] = 'This auth plugin is not enabled in configuration, consider disabling it.'; $lang['install_url'] = 'Install from URL:'; $lang['install_upload'] = 'Upload Extension:'; -- cgit v1.2.3