Browse Source

Increase cache time of javascript and css since the files are hashed

pull/2168/head
Gabe Kangas 4 years ago
parent
commit
cb65dde46a
No known key found for this signature in database
GPG Key ID: 9A56337728BC81EA
  1. 2
      utils/utils.go

2
utils/utils.go

@ -186,7 +186,7 @@ func GetCacheDurationSecondsForPath(filePath string) int {
return 20 return 20
} else if fileExtension == ".js" || fileExtension == ".css" { } else if fileExtension == ".js" || fileExtension == ".css" {
// Cache javascript & CSS // Cache javascript & CSS
return 60 * 60 * 3 return 60 * 60 * 24 * 7
} else if fileExtension == ".ts" || fileExtension == ".woff2" { } else if fileExtension == ".ts" || fileExtension == ".woff2" {
// Cache video segments as long as you want. They can't change. // Cache video segments as long as you want. They can't change.
// This matters most for local hosting of segments for recordings // This matters most for local hosting of segments for recordings

Loading…
Cancel
Save