summaryrefslogtreecommitdiffstats
path: root/core/Controller
diff options
context:
space:
mode:
authorJohn Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>2018-06-29 16:12:47 +0200
committerJulius Härtl <jus@bitgrid.net>2018-07-19 08:16:58 +0200
commitccd70a4099f96071ad6a5655bcae81fd3bf4a38a (patch)
tree16e658358ea76fe9114dd6464fe7ea0da988e5be /core/Controller
parent29ff7efe9a5be16b133a1ee4e43d6d2155b6a21c (diff)
downloadnextcloud-server-ccd70a4099f96071ad6a5655bcae81fd3bf4a38a.tar.gz
nextcloud-server-ccd70a4099f96071ad6a5655bcae81fd3bf4a38a.zip
use built in response cacheFor function
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
Diffstat (limited to 'core/Controller')
-rw-r--r--core/Controller/SvgController.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/Controller/SvgController.php b/core/Controller/SvgController.php
index 26cead8913e..b8e59d57d9f 100644
--- a/core/Controller/SvgController.php
+++ b/core/Controller/SvgController.php
@@ -123,7 +123,7 @@ class SvgController extends Controller {
// Set cache control
$ttl = 31536000;
- $response->addHeader('Cache-Control', 'max-age=' . $ttl . ', immutable');
+ $response->cacheFor($ttl);
$response->addHeader('Content-Disposition', 'inline; filename="' . $fileName . '.svg"');
$expires = new \DateTime();
$expires->setTimestamp($this->timeFactory->getTime());