6 declare(strict_types=1);
28 $this->scopeConfig = $scopeConfig;
40 return (
bool)$this->scopeConfig->getValue(
'reports/options/enabled')
41 && (bool)$this->scopeConfig->getValue($this->getConfigPathByEventType($reportEventType));
49 private function getConfigPathByEventType(
string $reportEventType): string
60 if (!isset($typeToPathMap[$reportEventType])) {
62 __(
'System configuration is not found for report event type "%1"', $reportEventType)
66 return $typeToPathMap[$reportEventType];
isReportEnabled(string $reportEventType)
const EVENT_PRODUCT_TO_WISHLIST
const EVENT_WISHLIST_SHARE
const EVENT_PRODUCT_COMPARE
const EVENT_PRODUCT_TO_CART
__construct(ScopeConfigInterface $scopeConfig)