Skip to content

Commit

Permalink
Fix PHP 8.1 strict types bug with html_entity_decode
Browse files Browse the repository at this point in the history
  • Loading branch information
stevebauman committed Sep 21, 2022
1 parent d679be5 commit 8ad10c2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Ldap.php
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ public function parseResult($result, &$errorCode, &$dn, &$errorMessage, &$referr
public function bind($username, $password)
{
return $this->bound = $this->executeFailableOperation(function () use ($username, $password) {
return ldap_bind($this->connection, $username, html_entity_decode($password));
return ldap_bind($this->connection, $username, $password ? html_entity_decode($password) : null);
});
}

Expand Down

0 comments on commit 8ad10c2

Please sign in to comment.