fix(web): update server to handle database management interface

This commit is contained in:
Masahiko AMANO 2023-02-15 15:31:32 +03:00
parent 1f3d015870
commit 8eb11f6035
2 changed files with 7 additions and 7 deletions

File diff suppressed because one or more lines are too long

View File

@ -220,7 +220,7 @@ func main() {
} }
public_fs := http.FileServer(http.Dir("/srv/www/tanabata")) public_fs := http.FileServer(http.Dir("/srv/www/tanabata"))
http.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) { http.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
if r.URL.Path == "/tfm" { if r.URL.Path == "/tfm" || r.URL.Path == "/tdbms" {
r.URL.Path += "/" r.URL.Path += "/"
} }
if r.URL.Path[len(r.URL.Path)-1] != '/' && path.Ext(r.URL.Path) == "" { if r.URL.Path[len(r.URL.Path)-1] != '/' && path.Ext(r.URL.Path) == "" {