We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 24429b2 + c61bfd9 commit 33d930cCopy full SHA for 33d930c
Views/Mustache.php
@@ -58,10 +58,10 @@ class Mustache extends \Slim\View
58
*/
59
public function render($template)
60
{
61
- require_once self::$mustacheDirectory . '/Mustache.php';
62
- $m = new \Mustache();
+ require_once self::$mustacheDirectory . '/Autoloader.php';
+ \Mustache_Autoloader::register(dirname(self::$mustacheDirectory));
63
+ $m = new \Mustache_Engine();
64
$contents = file_get_contents($this->getTemplatesDirectory() . '/' . ltrim($template, '/'));
-
65
return $m->render($contents, $this->data);
66
}
67
0 commit comments