diff --git a/source/php/Init.php b/source/php/Init.php index b3f19e8d..bcf20798 100644 --- a/source/php/Init.php +++ b/source/php/Init.php @@ -37,7 +37,10 @@ public function __construct($externalViewPaths) { if(is_array($viewPaths) && !empty($viewPaths)) { foreach ($viewPaths as $path) { - $blade->addViewPath(rtrim($path, DIRECTORY_SEPARATOR)); + $directory = rtrim($path, DIRECTORY_SEPARATOR); + if(is_dir($directory)) { + $blade->addViewPath(rtrim($path, DIRECTORY_SEPARATOR)); + } } } else { throw new \Exception("View paths not defined.");