code: protected function validateRegistrationOptin()
      {
          $return = true;
          $optin = (int) $this->getRequestParameter('oegdproptin_userregistration');
          //1 is for guest buy, 3 for account creation
          $registrationOption = (int) $this->getRequestParameter('option');
          if (\OxidEsales\Eshop\Core\Registry::getConfig()->getConfigParam('blOeGdprOptinUserRegistration') && (3 == $registrationOption) && (1 !== $optin)) {
              $return = false;
          }
          return $return;
      }
docs: Validate user registration optin.
  
  @return bool