Skip to content
Snippets Groups Projects
Commit 889088f7 authored by Morris Jobke's avatar Morris Jobke Committed by Robin Appelman
Browse files

Fix template rendering for 'blank' templates

parent 2946a63f
No related branches found
No related tags found
No related merge requests found
......@@ -134,8 +134,10 @@ class TemplateResponse extends Response {
* @return string the rendered html
*/
public function render(){
// \OCP\Template needs an empty string instead of 'blank' for an unwrapped response
$renderAs = $this->renderAs === 'blank' ? '' : $this->renderAs;
$template = new \OCP\Template($this->appName, $this->templateName, $this->renderAs);
$template = new \OCP\Template($this->appName, $this->templateName, $renderAs);
foreach($this->params as $key => $value){
$template->assign($key, $value);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment