|
8 | 8 | * License: GNU/GPLv2
|
9 | 9 | * @see LICENSE.txt
|
10 | 10 | *
|
11 |
| - * This file: The loader (last modified: 2021.07.10). |
| 11 | + * This file: The loader (last modified: 2021.08.25). |
12 | 12 | */
|
13 | 13 |
|
14 | 14 | namespace phpMussel\Core;
|
@@ -285,7 +285,7 @@ public function __construct(
|
285 | 285 | $Configuration = $this->readFile($this->AssetsPath . 'config.yml')
|
286 | 286 | ) {
|
287 | 287 | $Defaults = [];
|
288 |
| - $this->YAML->process($Configuration, $Defaults); |
| 288 | + $this->YAML->process($Configuration, $Defaults, 0, true); |
289 | 289 | if (isset($Defaults)) {
|
290 | 290 | $this->fallback($Defaults);
|
291 | 291 | $this->ConfigurationDefaults = array_merge_recursive($this->ConfigurationDefaults, $Defaults);
|
@@ -335,9 +335,10 @@ public function __construct(
|
335 | 335 | /** Instantiate the request class. */
|
336 | 336 | $this->Request = new \Maikuolan\Common\Request();
|
337 | 337 | $this->Request->DefaultTimeout = $this->Configuration['core']['default_timeout'];
|
338 |
| - $this->Request->Channels = ( |
339 |
| - $Channels = $this->readFileBlocks($this->AssetsPath . 'channels.yaml') |
340 |
| - ) ? (new \Maikuolan\Common\YAML($Channels))->Data : []; |
| 338 | + $ChannelsDataArray = []; |
| 339 | + $this->YAML->process($this->readFileBlocks($this->AssetsPath . 'channels.yaml'), $ChannelsDataArray); |
| 340 | + $this->Request->Channels = $ChannelsDataArray ?: []; |
| 341 | + unset($ChannelsDataArray); |
341 | 342 | if (!isset($this->Request->Channels['Triggers'])) {
|
342 | 343 | $this->Request->Channels['Triggers'] = [];
|
343 | 344 | }
|
|
0 commit comments