diff --git a/system/src/Grav/Common/Page/Pages.php b/system/src/Grav/Common/Page/Pages.php index ac0e9e70f..f72b27ede 100644 --- a/system/src/Grav/Common/Page/Pages.php +++ b/system/src/Grav/Common/Page/Pages.php @@ -392,8 +392,8 @@ class Pages { if (!self::$types) { self::$types = new Types(); - self::$types->scanBlueprints('theme://blueprints/'); - self::$types->scanTemplates('theme://templates/'); + file_exists('theme://blueprints/') && self::$types->scanBlueprints('theme://blueprints/'); + file_exists('theme://templates/') && self::$types->scanTemplates('theme://templates/'); $event = new Event(); $event->types = self::$types;