diff options
author | Roeland Jago Douma <rullzer@users.noreply.github.com> | 2018-02-19 10:40:45 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-02-19 10:40:45 +0100 |
commit | 9c33ebad5d4fc930bb2fc05f31306954e44d1cac (patch) | |
tree | 9bea5016d93081f747238baed4bc93d40a8e5eed /lib/private/legacy/files.php | |
parent | b3ca73dc277f7c5b00f2175d5c42919f044631c0 (diff) | |
parent | 70b1f510f2eab2276beab2e0b47d08f04c63c966 (diff) | |
download | nextcloud-server-9c33ebad5d4fc930bb2fc05f31306954e44d1cac.tar.gz nextcloud-server-9c33ebad5d4fc930bb2fc05f31306954e44d1cac.zip |
Merge pull request #8366 from nextcloud/remove-disable-caching-headers
Use normal header() calls instead of private method calls
Diffstat (limited to 'lib/private/legacy/files.php')
-rw-r--r-- | lib/private/legacy/files.php | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/private/legacy/files.php b/lib/private/legacy/files.php index 24324bca095..def9f82fab9 100644 --- a/lib/private/legacy/files.php +++ b/lib/private/legacy/files.php @@ -75,7 +75,9 @@ class OC_Files { private static function sendHeaders($filename, $name, array $rangeArray) { OC_Response::setContentDispositionHeader($name, 'attachment'); header('Content-Transfer-Encoding: binary', true); - OC_Response::disableCaching(); + header('Pragma: public');// enable caching in IE + header('Expires: 0'); + header("Cache-Control: must-revalidate, post-check=0, pre-check=0"); $fileSize = \OC\Files\Filesystem::filesize($filename); $type = \OC::$server->getMimeTypeDetector()->getSecureMimeType(\OC\Files\Filesystem::getMimeType($filename)); if ($fileSize > -1) { |