summaryrefslogtreecommitdiffstats
path: root/apps/files/download.php
diff options
context:
space:
mode:
Diffstat (limited to 'apps/files/download.php')
-rw-r--r--apps/files/download.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/files/download.php b/apps/files/download.php
index 1af576051bd..c85051e0f4e 100644
--- a/apps/files/download.php
+++ b/apps/files/download.php
@@ -43,7 +43,7 @@ $ftype=\OC_Helper::getSecureMimeType(\OC\Files\Filesystem::getMimeType( $filenam
header('Content-Type:'.$ftype);
OCP\Response::setContentDispositionHeader(basename($filename), 'attachment');
OCP\Response::disableCaching();
-header('Content-Length: '.\OC\Files\Filesystem::filesize($filename));
+OCP\Response::setContentLengthHeader(\OC\Files\Filesystem::filesize($filename));
OC_Util::obEnd();
\OC\Files\Filesystem::readfile( $filename );