mirror of https://github.com/perkeep/perkeep.git
pkg/server: redirect "/" to "/ui/"
Fixes #593 Change-Id: I6d98c3560aa329e9fd8a30012a8f283903d7d274
This commit is contained in:
parent
1a483159c3
commit
89488a3cf4
|
@ -145,6 +145,10 @@ func (rh *RootHandler) ServeHTTP(rw http.ResponseWriter, req *http.Request) {
|
|||
if rh.Stealth {
|
||||
return
|
||||
}
|
||||
if req.RequestURI == "/" && rh.ui != nil {
|
||||
http.Redirect(rw, req, "/ui/", http.StatusMovedPermanently)
|
||||
return
|
||||
}
|
||||
if req.URL.Path == "/favicon.ico" {
|
||||
ServeStaticFile(rw, req, Files, "favicon.ico")
|
||||
return
|
||||
|
|
Loading…
Reference in New Issue