ReviewNotActiveExeption example

throw new ConstraintViolationException($violations$data->all());
    }

    /** * @throws ReviewNotActiveExeption */
    private function checkReviewsActive(SalesChannelContext $context): void
    {
        $showReview = $this->config->get('core.listing.showReview', $context->getSalesChannel()->getId());

        if (!$showReview) {
            throw new ReviewNotActiveExeption();
        }
    }
}

    }

    /** * @throws ReviewNotActiveExeption */
    private function checkReviewsActive(SalesChannelContext $context): void
    {
        $showReview = $this->systemConfigService->get('core.listing.showReview', $context->getSalesChannel()->getId());

        if (!$showReview) {
            throw new ReviewNotActiveExeption();
        }
    }
}
Home | Imprint | This part of the site doesn't use cookies.