Fixed small bug that used article.Link instead of correct path for article deletion

This commit is contained in:
Jason Streifling 2024-08-31 11:27:03 +02:00
parent edb448413b
commit b02a882ed7

View File

@ -572,7 +572,8 @@ func ReviewArticleForDeletion(c *b.Config, db *b.DB, s *b.CookieStore) http.Hand
return
}
contentBytes, err := os.ReadFile(article.Link)
articleAbsName := fmt.Sprint(c.ArticleDir, "/", article.ID, ".md")
contentBytes, err := os.ReadFile(articleAbsName)
if err != nil {
log.Println(err)
http.Error(w, err.Error(), http.StatusInternalServerError)