Controller/ReviewController.php
public function isReviewOptInError()
    {
        $formSent = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('rvw_oegdproptin') !== null;
        $review = oxNew(\OxidEsales\Eshop\Application\Controller\ReviewController::class);
        $result = false;

        if ($formSent && !$review->validateOptIn()) {
            $result = true;
        }

        return $result;
    }
public function isReviewOptInError()
    {
        $formSent = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('rvw_oegdproptin') !== null;
        $review = oxNew(\OxidEsales\Eshop\Application\Controller\ReviewController::class);
        $result = false;

        if ($formSent && !$review->validateOptIn()) {
            $result = true;
        }

        return $result;
    }
Check if form was sent but optin not checked when required

@return bool