Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions ViewModel/Warranty.php
Original file line number Diff line number Diff line change
Expand Up @@ -413,18 +413,18 @@ public function itemHasLeadWarrantyInQuote($orderItem): bool
* Check does quote have warranty item for the item
* Kept for backwards compatibility with Hyva module
*
* @param string $sku
* @param int $quoteItemId
* @return bool
*/
public function isWarrantyInQuote(string $sku): bool
public function isWarrantyInQuote(int $quoteItemId): bool
{
try {
$quote = $this->checkoutSession->getQuote();
} catch (LocalizedException $exception) {
$quote = null;
}
if ($quote) {
$hasWarranty = $this->hasWarranty($quote, $sku);
$hasWarranty = $this->hasWarranty($quote, $quoteItemId);
}
return $hasWarranty ?? false;
}
Expand Down