[Iter] cs fix

This commit is contained in:
azjezz 2020-09-01 02:10:27 +01:00
parent 1aad753ca2
commit 4e8c2ffaf7
4 changed files with 33 additions and 32 deletions

View File

@ -4,8 +4,8 @@ declare(strict_types=1);
namespace Psl\Iter; namespace Psl\Iter;
use Psl\Internal;
use Generator; use Generator;
use Psl\Internal;
/** /**
* Filter out null values from the given iterable. * Filter out null values from the given iterable.
@ -24,7 +24,7 @@ function filter_nulls(iterable $iterable): Iterator
{ {
return Internal\lazy_iterator(static function () use ($iterable): Generator { return Internal\lazy_iterator(static function () use ($iterable): Generator {
foreach ($iterable as $value) { foreach ($iterable as $value) {
if ($value !== null) { if (null !== $value) {
yield $value; yield $value;
} }
} }

View File

@ -83,5 +83,6 @@ function range($start, $end, $step = null): Iterator
yield $i; yield $i;
} }
} }
}); }
);
} }