Fix regression when startup() method of some "by role plugins" could be called when not expected, causing PHP errors
This commit is contained in:
parent
915b86bb80
commit
1abc73cf34
1 changed files with 2 additions and 2 deletions
|
@ -331,8 +331,8 @@ class kolab_auth extends rcube_plugin
|
|||
// Some plugins e.g. kolab_2fa use 'startup' hook to
|
||||
// register other hooks, but when called on 'authenticate' hook
|
||||
// we're already after 'startup', so we'll call it directly
|
||||
if ($loaded && $startup && ($plugin = $this->api->get_plugin($plugin))
|
||||
&& method_exists($plugin, 'startup')
|
||||
if ($loaded && $startup && $plugin == 'kolab_2fa'
|
||||
&& ($plugin = $this->api->get_plugin($plugin))
|
||||
) {
|
||||
$plugin->startup(array('task' => $rcmail->task, 'action' => $rcmail->action));
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue