getPriceInfo()->getPrice(FinalPrice::PRICE_CODE)->getValue(); } $discount = null; foreach ($product->getPriceInfo()->getPrices() as $price) { if ($price instanceof DiscountProviderInterface && $price->getDiscountPercent()) { $discount = min($price->getDiscountPercent(), $discount ?: $price->getDiscountPercent()); } } return (null !== $discount) ? $discount/100 * $value : $value; } }