From df9dfb0368831b84cb61cbd64fd856157a405874 Mon Sep 17 00:00:00 2001 From: MaysWind Date: Mon, 31 May 2021 00:09:24 +0800 Subject: [PATCH] add missed router path --- cmd/webserver.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cmd/webserver.go b/cmd/webserver.go index ad65f68d..bf9ff41d 100644 --- a/cmd/webserver.go +++ b/cmd/webserver.go @@ -90,6 +90,10 @@ func startWebServer(c *cli.Context) error { router.NoMethod(bindApi(api.Default.MethodNotAllowed)) router.StaticFile("/", filepath.Join(config.StaticRootPath, "index.html")) + router.Static("/js", filepath.Join(config.StaticRootPath, "js")) + router.Static("/css", filepath.Join(config.StaticRootPath, "css")) + router.Static("/img", filepath.Join(config.StaticRootPath, "img")) + router.Static("/fonts", filepath.Join(config.StaticRootPath, "fonts")) router.StaticFile("robots.txt", filepath.Join(config.StaticRootPath, "robots.txt")) router.StaticFile("favicon.ico", filepath.Join(config.StaticRootPath, "favicon.ico"))