mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-07 19:04:41 -04:00
Merge pull request #821 from DraperStudio/develop
Use object_get to retrieve a config field
This commit is contained in:
commit
9dd1a106a9
@ -60,13 +60,7 @@ class AccountGateway extends EntityModel
|
|||||||
|
|
||||||
public function getConfigField($field)
|
public function getConfigField($field)
|
||||||
{
|
{
|
||||||
$config = $this->getConfig();
|
return object_get($this->getConfig(), $field, false);
|
||||||
|
|
||||||
if (!$field || !property_exists($config, $field)) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
return $config->$field;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public function getPublishableStripeKey()
|
public function getPublishableStripeKey()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user