diff options
author | Morgan Bazalgette <git@howl.moe> | 2018-02-03 23:37:05 +0100 |
---|---|---|
committer | Lauris BH <lauris@nix.lv> | 2018-02-04 00:37:05 +0200 |
commit | 17655cdf1b409521262d5d54eb19884d307c47ce (patch) | |
tree | b06d15367afc6bd4f915c0e8b9272241bb3f4a3c /modules/public/dynamic.go | |
parent | 77f8bad2fb7a6a4ab57b398cb89e6889f76ffe8a (diff) | |
download | gitea-17655cdf1b409521262d5d54eb19884d307c47ce.tar.gz gitea-17655cdf1b409521262d5d54eb19884d307c47ce.zip |
Enable caching on assets and avatars (#3376)
* Enable caching on assets and avatars
Fixes #3323
* Only set avatar in user BeforeUpdate when there is no avatar set
* add error checking after stat
* gofmt
* Change cache time for avatars to an hour
Diffstat (limited to 'modules/public/dynamic.go')
-rw-r--r-- | modules/public/dynamic.go | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/modules/public/dynamic.go b/modules/public/dynamic.go index c196d67baa..282db44970 100644 --- a/modules/public/dynamic.go +++ b/modules/public/dynamic.go @@ -12,10 +12,5 @@ import ( // Static implements the macaron static handler for serving assets. func Static(opts *Options) macaron.Handler { - return macaron.Static( - opts.Directory, - macaron.StaticOptions{ - SkipLogging: opts.SkipLogging, - }, - ) + return opts.staticHandler(opts.Directory) } |