code: 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;
      }
docs: Check if form was sent but optin not checked when required
  
  @return bool