Skip to content

Commit

Permalink
Let variables be default nullable values (#181)
Browse files Browse the repository at this point in the history
  • Loading branch information
peter279k authored Sep 22, 2023
1 parent 20c3aff commit c141f00
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/Reader/CSV/RowIterator.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ final class RowIterator implements RowIteratorInterface
private int $numReadRows = 0;

/** @var null|Row Buffer used to store the current row, while checking if there are more rows to read */
private ?Row $rowBuffer;
private ?Row $rowBuffer = null;

/** @var bool Indicates whether all rows have been read */
private bool $hasReachedEndOfFile = false;
Expand Down
4 changes: 2 additions & 2 deletions src/Reader/ODS/RowIterator.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ final class RowIterator implements RowIteratorInterface
private Row $currentlyProcessedRow;

/** @var null|Row Buffer used to store the current row, while checking if there are more rows to read */
private ?Row $rowBuffer;
private ?Row $rowBuffer = null;

/** @var bool Indicates whether all rows have been read */
private bool $hasReachedEndOfFile = false;
Expand All @@ -57,7 +57,7 @@ final class RowIterator implements RowIteratorInterface
private int $nextRowIndexToBeProcessed = 1;

/** @var null|Cell Last processed cell (because when reading cell at column N+1, cell N is processed) */
private ?Cell $lastProcessedCell;
private ?Cell $lastProcessedCell = null;

/** @var int Number of times the last processed row should be repeated */
private int $numRowsRepeated = 1;
Expand Down
2 changes: 1 addition & 1 deletion src/Reader/XLSX/RowIterator.php
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ final class RowIterator implements RowIteratorInterface
private Row $currentlyProcessedRow;

/** @var null|Row Buffer used to store the current row, while checking if there are more rows to read */
private ?Row $rowBuffer;
private ?Row $rowBuffer = null;

/** @var bool Indicates whether all rows have been read */
private bool $hasReachedEndOfFile = false;
Expand Down

0 comments on commit c141f00

Please sign in to comment.