From: Michael M Slusarz Date: Thu, 20 Jan 2011 17:49:47 +0000 (-0700) Subject: Bug #9524: Fix method signature X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=18e1910c0c33c1386112df84eb3f1a888b01236d;p=horde.git Bug #9524: Fix method signature --- diff --git a/turba/lib/Driver/Ldap.php b/turba/lib/Driver/Ldap.php index fc1018dd1..b2a6e5cba 100644 --- a/turba/lib/Driver/Ldap.php +++ b/turba/lib/Driver/Ldap.php @@ -41,8 +41,12 @@ class Turba_Driver_Ldap extends Turba_Driver * * @param $params Hash containing additional configuration parameters. */ - public function __construct($params) + public function __construct($name = '', $params = array()) { + if (!Horde_Util::extensionExists('ldap')) { + throw new Turba_Exception(_("LDAP support is required but the LDAP module is not available or not loaded.")); + } + $params = array_merge(array( 'charset' => '', 'deref' => LDAP_DEREF_NEVER, @@ -53,10 +57,7 @@ class Turba_Driver_Ldap extends Turba_Driver 'server' => 'localhost' ), $params); - parent::__construct($params); - if (!Horde_Util::extensionExists('ldap')) { - throw new Turba_Exception(_("LDAP support is required but the LDAP module is not available or not loaded.")); - } + parent::__construct($name, $params); if (!($this->_ds = @ldap_connect($this->_params['server'], $this->_params['port']))) { throw new Turba_Exception(_("Connection failure"));