if ( !is_callable( $renderer ) ) {
throw new RuntimeException( "Requested template, {$templateName}, is not callable" );
}
- return $this->renderers[$templateName] = $renderer;
+ $this->renderers[$templateName] = $renderer;
+ return $renderer;
}
/**
array(
// Do not add more flags here without discussion.
// If you do add more flags, be sure to update unit tests as well.
- 'flags' => LightnCandy::FLAG_ERROR_EXCEPTION
+ 'flags' => LightnCandy::FLAG_ERROR_EXCEPTION,
+ 'basedir' => $this->templateDir,
+ 'fileext' => '.mustache',
)
);
}