Commit ddde85cd authored by akhu's avatar akhu

Fix processed rules not nullable

parent 95b45b22
......@@ -28,7 +28,7 @@ class ProcessedRules
private $dateRule;
/**
* rule that defines rule on prices
* @var ProcessedPriceRule
* @var null|ProcessedPriceRule
*/
private $priceRule;
/**
......@@ -43,12 +43,12 @@ class ProcessedRules
private $itemRule;
/**
* summarizes all rules matching, true if all rules are matched
* @var bool
* @var null|bool
*/
private $allRulesMatched;
/**
* total price of items that matched ItemRule
* @var float
* @var null|float
*/
private $totalPriceOfMatchedItems;
......@@ -101,17 +101,17 @@ class ProcessedRules
}
/**
* @return ProcessedPriceRule
* @return null|ProcessedPriceRule
*/
public function getPriceRule(): ProcessedPriceRule
public function getPriceRule(): ?ProcessedPriceRule
{
return $this->priceRule;
}
/**
* @param ProcessedPriceRule $priceRule
* @param ?ProcessedPriceRule $priceRule
*/
public function setPriceRule(ProcessedPriceRule $priceRule): void
public function setPriceRule(?ProcessedPriceRule $priceRule): void
{
$this->priceRule = $priceRule;
}
......@@ -165,21 +165,21 @@ class ProcessedRules
}
/**
* @return float
* @return null\float
*/
public function getTotalPriceOfMatchedItems(): float
public function getTotalPriceOfMatchedItems(): ?float
{
return $this->totalPriceOfMatchedItems;
}
/**
* @param float $totalPriceOfMatchedItems
* @param null\float $totalPriceOfMatchedItems
*/
public function setTotalPriceOfMatchedItems(float $totalPriceOfMatchedItems): void
public function setTotalPriceOfMatchedItems(?float $totalPriceOfMatchedItems): void
{
$this->totalPriceOfMatchedItems = $totalPriceOfMatchedItems;
}
}
\ No newline at end of file
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment