summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorThomas Müller <thomas.mueller@tmit.eu>2014-07-30 10:31:15 +0200
committerThomas Müller <thomas.mueller@tmit.eu>2014-07-30 10:31:15 +0200
commit7d6221d25dd02066eadb07325fdef0581bf31771 (patch)
tree4f17b97deb2791a2424cb927b6cc0fdb98f72bf2 /lib
parent47e72917e5eac67d18b80097d2368db65ee928c2 (diff)
parent889088f72da5aa3ce10f2f6c43bb66d00f5a1423 (diff)
downloadnextcloud-server-7d6221d25dd02066eadb07325fdef0581bf31771.tar.gz
nextcloud-server-7d6221d25dd02066eadb07325fdef0581bf31771.zip
Merge pull request #9914 from owncloud/fix-appframework-blank-template
Fix template rendering for 'blank' templates
Diffstat (limited to 'lib')
-rw-r--r--lib/public/appframework/http/templateresponse.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/public/appframework/http/templateresponse.php b/lib/public/appframework/http/templateresponse.php
index 02589f4e2a4..c74d3b60254 100644
--- a/lib/public/appframework/http/templateresponse.php
+++ b/lib/public/appframework/http/templateresponse.php
@@ -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);