diff --git a/classes/view/handlebars.php b/classes/view/handlebars.php index 2ee0201..62544e1 100644 --- a/classes/view/handlebars.php +++ b/classes/view/handlebars.php @@ -36,6 +36,13 @@ protected function process_file($file_override = false) // do we need to compile? if ( ! is_file($compiled) or filemtime($file) > filemtime($compiled) or \Config::get('parser.View_Handlebars.force_compile', true)) { + // make sure the directory exists + if ( ! is_dir($compiled_path = dirname($compiled))) + { + \File::create_dir($path, substr($compiled_path, strlen($path))); + } + + // write the compiled code file_put_contents($compiled, '