mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge pull request #5032 from patricknelson/issue-5028-yaml-errors-empty
FIX for #5028: Ensure empty YML configs don't break when merging them in.
This commit is contained in:
commit
17b42a3f89
@ -652,9 +652,11 @@ class SS_ConfigManifest {
|
|||||||
* @return void
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function mergeInYamlFragment(&$into, $fragment) {
|
public function mergeInYamlFragment(&$into, $fragment) {
|
||||||
|
if (is_array($fragment) || ($fragment instanceof Traversable)) {
|
||||||
foreach ($fragment as $k => $v) {
|
foreach ($fragment as $k => $v) {
|
||||||
Config::merge_high_into_low($into[$k], $v);
|
Config::merge_high_into_low($into[$k], $v);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user