diff options
author | Jarkko Lehtoranta <devel@jlranta.com> | 2017-07-16 13:05:48 +0300 |
---|---|---|
committer | Jarkko Lehtoranta <devel@jlranta.com> | 2017-07-23 14:50:01 +0300 |
commit | 6103677a910f6dbb6685019abcaba853611b86ea (patch) | |
tree | d2f913369fcf1767e41a3c31e773cbd4e9518142 /apps/user_ldap/lib/Connection.php | |
parent | 79fbed40649744c862c9f5c1e435c624bef9521b (diff) | |
download | nextcloud-server-6103677a910f6dbb6685019abcaba853611b86ea.tar.gz nextcloud-server-6103677a910f6dbb6685019abcaba853611b86ea.zip |
LDAP: Use imported exception in Connection class
Signed-off-by: Jarkko Lehtoranta <devel@jlranta.com>
Diffstat (limited to 'apps/user_ldap/lib/Connection.php')
-rw-r--r-- | apps/user_ldap/lib/Connection.php | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/apps/user_ldap/lib/Connection.php b/apps/user_ldap/lib/Connection.php index 799e63f268e..8f80e2905c3 100644 --- a/apps/user_ldap/lib/Connection.php +++ b/apps/user_ldap/lib/Connection.php @@ -543,7 +543,7 @@ class Connection extends LDAPUtility { if($bindStatus === true) { return $bindStatus; } - } catch (\OC\ServerNotAvailableException $e) { + } catch (ServerNotAvailableException $e) { if(trim($this->configuration->ldapBackupHost) === "") { throw $e; } @@ -586,16 +586,16 @@ class Connection extends LDAPUtility { $this->ldapConnectionRes = $this->ldap->connect($host, $port); if(!$this->ldap->setOption($this->ldapConnectionRes, LDAP_OPT_PROTOCOL_VERSION, 3)) { - throw new \OC\ServerNotAvailableException('Could not set required LDAP Protocol version.'); + throw new ServerNotAvailableException('Could not set required LDAP Protocol version.'); } if(!$this->ldap->setOption($this->ldapConnectionRes, LDAP_OPT_REFERRALS, 0)) { - throw new \OC\ServerNotAvailableException('Could not disable LDAP referrals.'); + throw new ServerNotAvailableException('Could not disable LDAP referrals.'); } if($this->configuration->ldapTLS) { if(!$this->ldap->startTls($this->ldapConnectionRes)) { - throw new \OC\ServerNotAvailableException('Start TLS failed, when connecting to LDAP host ' . $host . '.'); + throw new ServerNotAvailableException('Start TLS failed, when connecting to LDAP host ' . $host . '.'); } } |