Skip to content

Commit

Permalink
Fix type error; Sanitizer::validateEmail() should return bool (#168)
Browse files Browse the repository at this point in the history
  • Loading branch information
lens0021 authored Sep 21, 2024
1 parent cb1b7e0 commit 7c8e46e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions includes/HookHandlers/SpamEmail.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ public function onIsValidEmailAddr( $addr, &$result ) {
$match = preg_match( $regex, $addr );
AtEase::restoreWarnings();
if ( $match ) {
$result = false;
return false;
}
}
Expand All @@ -74,6 +75,7 @@ static function ( $block ) {
$this->databaseBlockStore->newListFromConds( [] )
) ) );
if ( in_array( $addr, $emails ) ) {
$result = false;
return false;
}
}
Expand Down

0 comments on commit 7c8e46e

Please sign in to comment.