diff options
author | Clement Wong <git@clement.hk> | 2020-05-10 11:06:56 +0200 |
---|---|---|
committer | Clement Wong <git@clement.hk> | 2020-05-10 11:24:08 +0200 |
commit | 401210d259be88918ea880aa32fde9e81fbe8bb2 (patch) | |
tree | 64b60536c5fa6f321fb6fcef61bfd226d3677711 /lib/public/AppFramework | |
parent | 0eeb6606796260bc3e0da3f2e6deb3a7cc522c3c (diff) | |
download | nextcloud-server-401210d259be88918ea880aa32fde9e81fbe8bb2.tar.gz nextcloud-server-401210d259be88918ea880aa32fde9e81fbe8bb2.zip |
Proxy server could cache http response when it is not private
Signed-off-by: Clement Wong <git@clement.hk>
Diffstat (limited to 'lib/public/AppFramework')
-rw-r--r-- | lib/public/AppFramework/Http/Response.php | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/public/AppFramework/Http/Response.php b/lib/public/AppFramework/Http/Response.php index a48580c789d..27a2fd3a008 100644 --- a/lib/public/AppFramework/Http/Response.php +++ b/lib/public/AppFramework/Http/Response.php @@ -107,10 +107,10 @@ class Response { */ public function cacheFor(int $cacheSeconds) { if ($cacheSeconds > 0) { - $this->addHeader('Cache-Control', 'max-age=' . $cacheSeconds . ', must-revalidate'); + $this->addHeader('Cache-Control', 'private, max-age=' . $cacheSeconds . ', must-revalidate'); // Old scool prama caching - $this->addHeader('Pragma', 'public'); + $this->addHeader('Pragma', 'private'); // Set expires header $expires = new \DateTime(); |