diff --git a/lib/Caxy/HtmlDiff/Table/AbstractTableElement.php b/lib/Caxy/HtmlDiff/Table/AbstractTableElement.php
index 305fdfe..711a1f1 100644
--- a/lib/Caxy/HtmlDiff/Table/AbstractTableElement.php
+++ b/lib/Caxy/HtmlDiff/Table/AbstractTableElement.php
@@ -17,7 +17,7 @@ abstract class AbstractTableElement
*
* @param \DOMElement|null $domNode
*/
- public function __construct(\DOMElement $domNode = null)
+ public function __construct(?\DOMElement $domNode = null)
{
$this->domNode = $domNode;
}
diff --git a/lib/Caxy/HtmlDiff/Table/TableCell.php b/lib/Caxy/HtmlDiff/Table/TableCell.php
index cf2c238..d52517f 100644
--- a/lib/Caxy/HtmlDiff/Table/TableCell.php
+++ b/lib/Caxy/HtmlDiff/Table/TableCell.php
@@ -25,7 +25,7 @@ public function getRow()
*
* @return $this
*/
- public function setRow(TableRow $row = null)
+ public function setRow(?TableRow $row = null)
{
$this->row = $row;
diff --git a/lib/Caxy/HtmlDiff/Table/TableDiff.php b/lib/Caxy/HtmlDiff/Table/TableDiff.php
index 34d51d4..fec9896 100644
--- a/lib/Caxy/HtmlDiff/Table/TableDiff.php
+++ b/lib/Caxy/HtmlDiff/Table/TableDiff.php
@@ -54,7 +54,7 @@ class TableDiff extends AbstractDiff
*
* @return self
*/
- public static function create($oldText, $newText, HtmlDiffConfig $config = null)
+ public static function create($oldText, $newText, ?HtmlDiffConfig $config = null)
{
$diff = new self($oldText, $newText);
@@ -549,7 +549,7 @@ protected function diffRows($oldRow, $newRow, array &$appliedRowSpans, $forceExp
*
* @return \DOMElement
*/
- protected function getNewCellNode(TableCell $oldCell = null, TableCell $newCell = null)
+ protected function getNewCellNode(?TableCell $oldCell = null, ?TableCell $newCell = null)
{
// If only one cell exists, use it
if (!$oldCell || !$newCell) {
@@ -654,7 +654,7 @@ protected function parseTableStructure($text)
* @param Table $table
* @param \DOMNode|null $node
*/
- protected function parseTable(Table $table, \DOMNode $node = null)
+ protected function parseTable(Table $table, ?\DOMNode $node = null)
{
if ($node === null) {
$node = $table->getDomNode();
diff --git a/lib/Caxy/HtmlDiff/Table/TableRow.php b/lib/Caxy/HtmlDiff/Table/TableRow.php
index 13c4628..eebb547 100644
--- a/lib/Caxy/HtmlDiff/Table/TableRow.php
+++ b/lib/Caxy/HtmlDiff/Table/TableRow.php
@@ -30,7 +30,7 @@ public function getTable()
*
* @return $this
*/
- public function setTable(Table $table = null)
+ public function setTable(?Table $table = null)
{
$this->table = $table;