| @@ -44,9 +44,9 @@ | ||
| 44 | 44 | } |
| 45 | 45 | /** |
| 46 | 46 | * Is the current element the first one? |
| 47 | 47 | */ |
| 48 | - public function isFirst(int $gridWidth = null) : bool | |
| 48 | + public function isFirst(?int $gridWidth = null) : bool | |
| 49 | 49 | { |
| 50 | 50 | return $this->counter === 1 || $gridWidth && $this->counter !== 0 && ($this->counter - 1) % $gridWidth === 0; |
| 51 | 51 | } |
| 52 | 52 | /** |
| @@ -51,9 +51,9 @@ | ||
| 51 | 51 | } |
| 52 | 52 | /** |
| 53 | 53 | * Is the current element the last one? |
| 54 | 54 | */ |
| 55 | - public function isLast(int $gridWidth = null) : bool | |
| 55 | + public function isLast(?int $gridWidth = null) : bool | |
| 56 | 56 | { |
| 57 | 57 | return !$this->hasNext() || $gridWidth && $this->counter % $gridWidth === 0; |
| 58 | 58 | } |
| 59 | 59 | /** |