From 17dfb5859090952f64cee3c4a70bb5d9081fb641 Mon Sep 17 00:00:00 2001 From: Franz Liedke Date: Fri, 16 Aug 2019 12:29:31 +0200 Subject: [PATCH] Don't fail when extend.php doesn't return an array Refs #1607. --- src/Foundation/Site.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/Foundation/Site.php b/src/Foundation/Site.php index 6f17f3f06..ba44d459c 100644 --- a/src/Foundation/Site.php +++ b/src/Foundation/Site.php @@ -61,6 +61,12 @@ class Site return []; } - return array_flatten(require $extenderFile); + $extenders = require $extenderFile; + + if (! is_array($extenders)) { + return []; + } + + return array_flatten($extenders); } }