Skip to content

Commit

Permalink
Update Times operation.
Browse files Browse the repository at this point in the history
  • Loading branch information
drupol committed Jul 6, 2020
1 parent fe32346 commit 3721100
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/Operation/Times.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,10 @@ final class Times extends AbstractOperation implements Operation
/**
* Times constructor.
*/
public function __construct(int $number = 0, ?callable $callback = null)
public function __construct(?int $number = null, ?callable $callback = null)
{
$number = $number ?? 0;

if (1 > $number) {
throw new InvalidArgumentException('Invalid parameter. $number must be greater than 1.');
}
Expand Down

0 comments on commit 3721100

Please sign in to comment.