public function Server::disconnect in Lightweight Directory Access Protocol (LDAP) 8.3
Disconnect (unbind) from an active LDAP server.
File
- ldap_servers/
src/ Entity/ Server.php, line 322
Class
- Server
- Defines the Server entity.
Namespace
Drupal\ldap_servers\EntityCode
public function disconnect() {
if (!$this->connection) {
// Never bound or not currently bound, so no need to disconnect.
}
else {
ldap_unbind($this->connection);
$this->connection = NULL;
}
}