Skip to content

Commit

Permalink
Revert "Move disabling of auth methods to init phase."
Browse files Browse the repository at this point in the history
This reverts commit b2b70dc.

Bug: 13840
  • Loading branch information
yunosh committed Feb 9, 2015
1 parent 754fc68 commit 881c8f1
Showing 1 changed file with 6 additions and 13 deletions.
19 changes: 6 additions & 13 deletions imp/lib/Application.php
Expand Up @@ -115,6 +115,12 @@ protected function _bootstrap()
$injector->bindFactory($key, $val, 'create');
}

/* Methods only available if admin config is set for this
* server/login. */
if (empty($injector->getInstance('IMP_Factory_Imap')->create()->config->admin)) {
$this->auth = array_diff($this->auth, array('add', 'list', 'remove'));
}

/* Set exception handler to handle uncaught
* Horde_Imap_Client_Exceptions. */
set_exception_handler(array($this, 'exceptionHandler'));
Expand All @@ -127,19 +133,6 @@ protected function _authenticated()
IMP_Auth::authenticateCallback();
}

/**
*/
protected function _init()
{
global $injector;

/* Methods only available if admin config is set for this
* server/login. */
if (empty($injector->getInstance('IMP_Factory_Imap')->create()->config->admin)) {
$this->auth = array_diff($this->auth, array('add', 'list', 'remove'));
}
}

/**
*/
public function logout()
Expand Down

0 comments on commit 881c8f1

Please sign in to comment.