aboutsummaryrefslogtreecommitdiff
path: root/pkg
diff options
context:
space:
mode:
Diffstat (limited to 'pkg')
-rw-r--r--pkg/ext/fileserver.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/pkg/ext/fileserver.go b/pkg/ext/fileserver.go
index ee4a80b..87c1ae8 100644
--- a/pkg/ext/fileserver.go
+++ b/pkg/ext/fileserver.go
@@ -15,11 +15,11 @@ type FileSystem interface {
// This is a VERY simple file server. It does not take a lot into consideration
// and it should only be used to return small predictable files, like in the
// static folder.
-func FileServer(rootFS FileSystem, rootPath string) fasthttp.RequestHandler {
+func FileServer(rootFS FileSystem) fasthttp.RequestHandler {
return func(ctx *fasthttp.RequestCtx) {
path := ctx.UserValue("filepath").(string)
- f, err := rootFS.Open(rootPath + path)
+ f, err := rootFS.Open(path)
if err != nil {
InternalServerError(ctx, err)
return