Skip to content

Commit

Permalink
Fix 'stripos(): Non-string needles will be interpreted as strings in …
Browse files Browse the repository at this point in the history
…the future'
  • Loading branch information
phil-davis committed Dec 19, 2019
1 parent 29709c7 commit 000dca2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/lib/Util/User/MemoryAccountMapper.php
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ public function search($fieldName, $pattern, $limit, $offset) {
return self::$accounts;
}
$match = \array_filter(self::$accounts, function (Account $a) use ($pattern) {
return \stripos($a->getUserId(), $pattern);
return \stripos($a->getUserId(), (string) $pattern);
});

return $match;
Expand Down

0 comments on commit 000dca2

Please sign in to comment.