Skip to content

Commit

Permalink
Fix file names and final price retrieval
Browse files Browse the repository at this point in the history
  • Loading branch information
avstudnitz committed Nov 17, 2023
1 parent 4970423 commit 83136b1
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 2 deletions.
File renamed without changes.
3 changes: 1 addition & 2 deletions src/Service/ProductsUpdateService.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
use Magento\Catalog\Model\ResourceModel\Product as ProductResource;
use Magento\Catalog\Model\ResourceModel\Product\Collection as ProductCollection;
use Magento\Catalog\Model\ResourceModel\Product\CollectionFactory as ProductCollectionFactory;
use Magento\Framework\Stdlib\DateTime\TimezoneInterface;
use Magento\Store\Api\Data\StoreInterface;
use Magento\Store\Model\StoreManagerInterface;

Expand Down Expand Up @@ -69,7 +68,7 @@ private function getProductsToCheck(StoreInterface $store): array

private function isProductSale(ProductInterface $product): bool
{
$finalPrice = (float)$product->getFinalPrice();
$finalPrice = (float)$product->getData('final_price');
$originalPrice = (float)$product->getPrice();
if (!$finalPrice || !$originalPrice) {
return false;
Expand Down
File renamed without changes.

0 comments on commit 83136b1

Please sign in to comment.