mirror of
https://github.com/appwrite/appwrite
synced 2026-05-23 00:49:02 +00:00
Add null check to hash
This commit is contained in:
parent
9fc7c1384a
commit
44cbfb2769
1 changed files with 1 additions and 1 deletions
|
|
@ -44,7 +44,7 @@ class PasswordHistory extends Password
|
|||
public function isValid($value): bool
|
||||
{
|
||||
foreach ($this->history as $hash) {
|
||||
if (Auth::passwordVerify($value, $hash, $this->algo, $this->algoOptions)) {
|
||||
if (!empty($hash) && Auth::passwordVerify($value, $hash, $this->algo, $this->algoOptions)) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue