From ad83d1dafac62bb28fda004f86129319a5c3e2ca Mon Sep 17 00:00:00 2001 From: Daniel Weipert Date: Sun, 6 Mar 2022 01:07:59 +0100 Subject: Refactor fixes --- src/Controllers/EntriesController.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/Controllers/EntriesController.php') diff --git a/src/Controllers/EntriesController.php b/src/Controllers/EntriesController.php index 13aa8e0..801fe7b 100644 --- a/src/Controllers/EntriesController.php +++ b/src/Controllers/EntriesController.php @@ -6,7 +6,7 @@ use Yosymfony\Toml\Toml; class EntriesController { - public function getEntries() + public function getEntries(string $formPath): array { /**@var Utilities $utilities*/ global $utilities; @@ -65,7 +65,7 @@ class EntriesController $entriesForDay = $utilities->scandir($dayPath); foreach ($entriesForDay as $entryForDay) { - $entry = Toml::parseFile("$dayPath/$entryForDay"); + $entry = Toml::parseFile($entryForDay); if (isset($_GET['flat'])) { $entries[] = $entry; } else { -- cgit v1.2.3