8
0
Mirror von https://git.d3data.de/3rdParty/captcha-module.git synchronisiert 2024-11-10 00:53:12 +01:00
captcha-module/Application/Shared/Options.php

25 Zeilen
679 B
PHP

<?php
declare(strict_types=1);
namespace OxidProfessionalServices\Captcha\Application\Shared;
use OxidEsales\EshopCommunity\Internal\Container\ContainerFactory;
use OxidEsales\EshopCommunity\Internal\Framework\Module\Facade\ModuleSettingServiceInterface;
trait Options
{
public const ENCRYPT_KEY = 'fq45QS09_fqyx09239QQ';
public function getOeCaptchaKey(): string
{
$bridge = ContainerFactory::getInstance()->getContainer()->get(ModuleSettingServiceInterface::class);
$key = $bridge->getString('oeCaptchaKey', 'oecaptcha')->toString();
if (!trim($key)) {
return static::ENCRYPT_KEY;
}
return $key;
}
}