fix error if configuration is missing
This commit is contained in:
parent
841d2c0879
commit
07b4f9523d
@ -93,7 +93,7 @@ class Configuration
|
|||||||
public function getOrderRecipientFields(): array
|
public function getOrderRecipientFields(): array
|
||||||
{
|
{
|
||||||
/** @var string[] $customFields */
|
/** @var string[] $customFields */
|
||||||
$customFields = Registry::getConfig()->getConfigParam(self::ORDER_RECFIELDS);
|
$customFields = Registry::getConfig()->getConfigParam(self::ORDER_RECFIELDS) ?: [];
|
||||||
|
|
||||||
array_walk(
|
array_walk(
|
||||||
$customFields,
|
$customFields,
|
||||||
@ -113,7 +113,7 @@ class Configuration
|
|||||||
public function getUserRecipientFields(): array
|
public function getUserRecipientFields(): array
|
||||||
{
|
{
|
||||||
/** @var string[] $customFields */
|
/** @var string[] $customFields */
|
||||||
$customFields = Registry::getConfig()->getConfigParam(self::USER_RECFIELDS);
|
$customFields = Registry::getConfig()->getConfigParam(self::USER_RECFIELDS) ?: [];
|
||||||
|
|
||||||
array_walk(
|
array_walk(
|
||||||
$customFields,
|
$customFields,
|
||||||
@ -138,7 +138,7 @@ class Configuration
|
|||||||
{
|
{
|
||||||
$checkCountryFieldName = $args[self::ARGS_CHECKKEYS] ? trim($checkCountryFieldName) : $checkCountryFieldName;
|
$checkCountryFieldName = $args[self::ARGS_CHECKKEYS] ? trim($checkCountryFieldName) : $checkCountryFieldName;
|
||||||
$checkPhoneFieldName = trim($checkPhoneFieldName);
|
$checkPhoneFieldName = trim($checkPhoneFieldName);
|
||||||
$allFieldNames = oxNew($args[self::ARGS_CHECKCLASS])->getFieldNames();
|
$allFieldNames = oxNew($args[self::ARGS_CHECKCLASS])->getFieldNames() ?: [];
|
||||||
|
|
||||||
array_walk($allFieldNames, function (&$value) {
|
array_walk($allFieldNames, function (&$value) {
|
||||||
$value = strtolower($value);
|
$value = strtolower($value);
|
||||||
|
Loading…
Reference in New Issue
Block a user