summaryrefslogtreecommitdiff
path: root/contrib/fs/dir.go
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/fs/dir.go')
-rw-r--r--contrib/fs/dir.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/fs/dir.go b/contrib/fs/dir.go
index 6292f67..4328c8f 100644
--- a/contrib/fs/dir.go
+++ b/contrib/fs/dir.go
@@ -75,7 +75,7 @@ func DirectoryDefault(fileSystem fs.FS, fileNames ...string) gus.Handler {
func DirectoryListing(fileSystem fs.FS, template *template.Template) gus.Handler {
return func(ctx context.Context, req *gus.Request) *gus.Response {
path, dirFile, resp := handleDir(req, fileSystem)
- if resp != nil {
+ if dirFile == nil {
return resp
}
defer dirFile.Close()