routes: change 303 -> 301 for /static -> /assets
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
* should enable users' browsers to make use of the status code and cache the redirect (in case anybody accesses the older version of the app and hits /static)
This commit is contained in:
parent
82bc22e192
commit
3cb2da457e
@ -21,7 +21,7 @@ func (a *App) SetupRoutes() {
|
||||
e.GET(
|
||||
"/static/*",
|
||||
func(c echo.Context) error {
|
||||
return c.Redirect(http.StatusSeeOther, c.Request().URL.Path)
|
||||
return c.Redirect(http.StatusMovedPermanently, c.Request().URL.Path)
|
||||
},
|
||||
middleware.Rewrite(
|
||||
map[string]string{"/static/*": "/assets/$1"},
|
||||
|
Loading…
Reference in New Issue
Block a user