FIX Providers API incorrect `array_key_exists`

- `array_key_exists` should search for they key `working_plan` within `$provider['settings']` and not `$provider['settings']['working_plan']`
This commit is contained in:
om-ha 2021-08-28 14:50:01 +03:00 committed by GitHub
parent 3a6f347246
commit a17c234698
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -102,7 +102,7 @@ class Providers extends API_V1_Controller {
throw new Exception('No settings property provided.'); throw new Exception('No settings property provided.');
} }
if ( ! array_key_exists('working_plan', $provider['settings']['working_plan'])) if ( ! array_key_exists('working_plan', $provider['settings']))
{ {
$provider['settings']['working_plan'] = $this->settings_model->get_setting('company_working_plan'); $provider['settings']['working_plan'] = $this->settings_model->get_setting('company_working_plan');
} }