Skip to content

Commit

Permalink
Refactor function call
Browse files Browse the repository at this point in the history
Signed-off-by: Nathanael Esayeas <nathanael.esayeas@protonmail.com>
  • Loading branch information
ghostwriter committed Feb 27, 2024
1 parent 8cc2eb6 commit 7b131df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion library/Mockery/Container.php
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ public function getKeyOfDemeterMockFor($method, $parent)
if (count($match) === 1) {
$res = array_values($match);

if (count($res) > 0) {
if ([] !== $res) {

Check failure on line 115 in library/Mockery/Container.php

View workflow job for this annotation

GitHub Actions / Psalm

RedundantConditionGivenDocblockType

library/Mockery/Container.php:115:17: RedundantConditionGivenDocblockType: Docblock-defined type non-empty-list<string> can never contain null (see https://psalm.dev/156)

Check failure on line 115 in library/Mockery/Container.php

View workflow job for this annotation

GitHub Actions / Psalm

RedundantConditionGivenDocblockType

library/Mockery/Container.php:115:17: RedundantConditionGivenDocblockType: Docblock-defined type non-empty-list<string> for $res is always non-empty-countable (see https://psalm.dev/156)
return $res[0];
}
}
Expand Down

0 comments on commit 7b131df

Please sign in to comment.