From 1d73524e418e57af9b79ce0a7ba2f209edac1d71 Mon Sep 17 00:00:00 2001 From: Daniel Rudolf Date: Tue, 2 May 2017 00:22:35 +0200 Subject: [PATCH] Search for content/index.md to determine the content dir to use --- lib/Pico.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/Pico.php b/lib/Pico.php index 2deeb80..4f6f4f0 100644 --- a/lib/Pico.php +++ b/lib/Pico.php @@ -761,9 +761,9 @@ class Pico if (!$this->config['content_dir']) { // try to guess the content directory - if (is_dir($this->getRootDir() . 'content')) { + if (is_file($this->getRootDir() . 'content/index' . $this->config['content_ext'])) { $this->config['content_dir'] = $this->getRootDir() . 'content/'; - } elseif (is_dir($this->getRootDir() . 'content-sample')) { + } elseif (is_file($this->getRootDir() . 'content-sample/index' . $this->config['content_ext'])) { $this->config['content_dir'] = $this->getRootDir() . 'content-sample/'; } else { $this->config['content_dir'] = $this->getVendorDir() . 'content-sample/';