Skip to content

Commit

Permalink
Update Split operation.
Browse files Browse the repository at this point in the history
  • Loading branch information
drupol committed May 26, 2020
1 parent b261a89 commit a323774
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/Operation/Split.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@
use Generator;
use loophp\collection\Contract\Operation;

use function count;

/**
* Class Split.
*/
Expand Down Expand Up @@ -54,7 +52,7 @@ public function on(iterable $collection): Closure
}
}

if (0 !== count($carry)) {
if ([] !== $carry) {
yield $carry;
}
};
Expand Down

0 comments on commit a323774

Please sign in to comment.