diff --git a/framework/core/src/Extension/Extension.php b/framework/core/src/Extension/Extension.php index 52fb73363..21600ffda 100644 --- a/framework/core/src/Extension/Extension.php +++ b/framework/core/src/Extension/Extension.php @@ -119,7 +119,13 @@ class Extension implements Arrayable return; } - $extenders = array_flatten((array) require $bootstrapper); + $extenders = require $bootstrapper; + + if (! is_array($extenders)) { + $extenders = [$extenders]; + } + + $extenders = array_flatten($extenders); foreach ($extenders as $extender) { // If an extension has not yet switched to the new bootstrap.php