Browse Source

Add preview gif to the short short cache time

pull/1376/head
Gabe Kangas 4 years ago
parent
commit
c7f8899b82
  1. 4
      utils/utils.go

4
utils/utils.go

@ -168,8 +168,8 @@ func GetCacheDurationSecondsForPath(filePath string) int {
filename := path.Base(filePath) filename := path.Base(filePath)
fileExtension := path.Ext(filePath) fileExtension := path.Ext(filePath)
if filename == "thumbnail.jpg" { if filename == "thumbnail.jpg" || filename == "preview.gif" {
// Thumbnails re-generate during live // Thumbnails & preview gif re-generate during live
return 20 return 20
} else if fileExtension == ".js" || fileExtension == ".css" { } else if fileExtension == ".js" || fileExtension == ".css" {
// Cache javascript & CSS // Cache javascript & CSS

Loading…
Cancel
Save