[MM-56651] fix: set cache duration (#26338)
* fix: set cache duration * fix: extra 0
Этот коммит содержится в:
@@ -35,7 +35,7 @@ var MediaContentTypes = [...]string{
|
|||||||
}
|
}
|
||||||
|
|
||||||
func WriteFileResponse(filename string, contentType string, contentSize int64, lastModification time.Time, webserverMode string, fileReader io.ReadSeeker, forceDownload bool, w http.ResponseWriter, r *http.Request) {
|
func WriteFileResponse(filename string, contentType string, contentSize int64, lastModification time.Time, webserverMode string, fileReader io.ReadSeeker, forceDownload bool, w http.ResponseWriter, r *http.Request) {
|
||||||
w.Header().Set("Cache-Control", "private, no-cache")
|
w.Header().Set("Cache-Control", "private, max-age=86400")
|
||||||
w.Header().Set("X-Content-Type-Options", "nosniff")
|
w.Header().Set("X-Content-Type-Options", "nosniff")
|
||||||
|
|
||||||
if contentSize > 0 {
|
if contentSize > 0 {
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user