diff --git a/api/src/Vfs/WebDAV.php b/api/src/Vfs/WebDAV.php index d002a5e963..1225598379 100644 --- a/api/src/Vfs/WebDAV.php +++ b/api/src/Vfs/WebDAV.php @@ -638,6 +638,11 @@ class WebDAV extends HTTP_WebDAV_Server_Filesystem { $_SERVER['ORIG_REQUEST_URI'] = $_SERVER['REQUEST_URI']; $_SERVER['REQUEST_URI'] = substr($_SERVER['REQUEST_URI'],0,$this->force_download); + // if download GET parameter contains a decent cache-buster, we allow caching for 10 days + if (strlen($_GET['download']) >= 8) + { + Api\Session::cache_control(864000); + } } parent::__construct(); } @@ -902,4 +907,4 @@ class WebDAV extends HTTP_WebDAV_Server_Filesystem } return parent::PUT($options); } -} +} \ No newline at end of file