From bfea63a4a8e3f676d29818e10098480d9b8c5aa3 Mon Sep 17 00:00:00 2001 From: Robert Lee Date: Wed, 19 Jun 2024 12:09:26 -0700 Subject: [PATCH 1/2] Force index.php as fallback template --- src/Roots/Acorn/Sage/Concerns/FiltersTemplates.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/Roots/Acorn/Sage/Concerns/FiltersTemplates.php b/src/Roots/Acorn/Sage/Concerns/FiltersTemplates.php index f5055562..e01f5c72 100644 --- a/src/Roots/Acorn/Sage/Concerns/FiltersTemplates.php +++ b/src/Roots/Acorn/Sage/Concerns/FiltersTemplates.php @@ -35,6 +35,12 @@ public function filterTemplateHierarchy($files) $templates = array_diff($templates, $pages); } + if (($index = array_search('index.php', $files)) !== false) { + unset($files[$index]); + + $templates[] = 'index.php'; + } + return [...$pages, ...$files, ...$templates]; } From 59dab7f0f1743ad59eba0d8d1feda446b73fbcc1 Mon Sep 17 00:00:00 2001 From: Brandon Date: Wed, 19 Jun 2024 14:49:35 -0500 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=9A=A8=20Run=20Pint?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/_ide-helpers.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/_ide-helpers.php b/src/_ide-helpers.php index 2bf68478..2877798f 100644 --- a/src/_ide-helpers.php +++ b/src/_ide-helpers.php @@ -9,7 +9,5 @@ * * @codeCoverageIgnore */ - class View - { - } + class View {} }