about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--internal/content/posts.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/content/posts.go b/internal/content/posts.go
index 467f36f..f8e2d16 100644
--- a/internal/content/posts.go
+++ b/internal/content/posts.go
@@ -99,8 +99,8 @@ func ReadPosts(config *Config, log *log.Logger) ([]Post, Tags, error) {
 		fn := f.Name()
 		if !f.IsDir() && path.Ext(fn) == ".md" {
 			output := path.Join(config.InputDir, outputReplacer.Replace(fn))
-			url := urlReplacer.Replace(strings.TrimPrefix("/", fn))
-			log.Debug("reading post", "post", fn)
+			url := path.Join("/", config.InputDir, urlReplacer.Replace(fn)) + "/"
+			log.Debug("reading post", "post", fn, "url", url)
 			matter, content, err := GetPost(path.Join(subdir, fn))
 			if err != nil {
 				return nil, nil, err