From 127a675fc7cd9cdb65e4b4caac21e0f259102ee8 Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Mon, 27 Jan 2025 21:42:41 +0100 Subject: serve files from Storage implementation --- internal/storage/files/writer.go | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'internal/storage/files/writer.go') diff --git a/internal/storage/files/writer.go b/internal/storage/files/writer.go index cd227c0..ce498e7 100644 --- a/internal/storage/files/writer.go +++ b/internal/storage/files/writer.go @@ -6,7 +6,6 @@ import ( "io" "os" "path/filepath" - "strings" "go.alanpearce.eu/x/log" @@ -177,8 +176,5 @@ func (f *Files) Mkdirp(dir string) error { } func (f *Files) join(filename string) string { - if strings.HasSuffix(filename, "/") { - filename = filename + "index.html" - } - return filepath.Join(f.outputDirectory, filename) + return filepath.Join(f.outputDirectory, pathNameToFileName(filename)) } -- cgit 1.4.1