mirror of
https://github.com/gofiber/fiber.git
synced 2025-02-19 13:27:53 +00:00
👷 Remove redundant validation of CacheDuration when checking static config
This commit is contained in:
parent
3eb8735794
commit
a5a50ab020
@ -349,9 +349,7 @@ func (app *App) registerStatic(prefix, root string, config ...Static) Router {
|
||||
if maxAge > 0 {
|
||||
cacheControlValue = "public, max-age=" + strconv.Itoa(maxAge)
|
||||
}
|
||||
if config[0].CacheDuration != 0 {
|
||||
fs.CacheDuration = config[0].CacheDuration
|
||||
}
|
||||
fs.CacheDuration = config[0].CacheDuration
|
||||
fs.Compress = config[0].Compress
|
||||
fs.AcceptByteRange = config[0].ByteRange
|
||||
fs.GenerateIndexPages = config[0].Browse
|
||||
|
Loading…
x
Reference in New Issue
Block a user