summaryrefslogtreecommitdiff
path: root/internal/router
diff options
context:
space:
mode:
authorLibravatar tobi <31960611+tsmethurst@users.noreply.github.com>2022-03-13 18:35:26 +0100
committerLibravatar GitHub <noreply@github.com>2022-03-13 18:35:26 +0100
commit4b4c935e02cee98d06b8824fc3751dfc88603e52 (patch)
tree2b3fdf6d47593a360acf9cc5bb9581fea7a55030 /internal/router
parent[bugfix] Fix html-escaped characters in content warnings (#426) (diff)
downloadgotosocial-4b4c935e02cee98d06b8824fc3751dfc88603e52.tar.xz
[bugfix] Fix bug where admin panel could not be accessed at `/admin` (#427)
* clarify comments * tidy up static serving + add /admin redirect
Diffstat (limited to 'internal/router')
-rw-r--r--internal/router/router.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/router/router.go b/internal/router/router.go
index 4b00f0eb0..57e0d36b2 100644
--- a/internal/router/router.go
+++ b/internal/router/router.go
@@ -47,7 +47,7 @@ type Router interface {
AttachMiddleware(handler gin.HandlerFunc)
// Attach 404 NoRoute handler
AttachNoRouteHandler(handler gin.HandlerFunc)
- // Add Gin StaticFile handler
+ // Add Gin StaticFS handler
AttachStaticFS(relativePath string, fs http.FileSystem)
// Start the router
Start()
@@ -62,7 +62,7 @@ type router struct {
certManager *autocert.Manager
}
-// Add Gin StaticFile handler
+// Add Gin StaticFS handler
func (r *router) AttachStaticFS(relativePath string, fs http.FileSystem) {
r.engine.StaticFS(relativePath, fs)
}