This commit is contained in:
Vaica committed 2026-06-02 00:23:04 +08:00
1 parent 5b4c086c73
commit db87655c87
58 files changed
+3184 -2128

No files matched your search

+1 -1
View File
@@ -164,7 +164,7 @@ export function createPost(frontMatter: PostFrontMatter, content: string): strin
const dirName = `${dateStr}-${titlePart}`;
const dirPath = path.join(CONTENT_DIR, year, dirName);
if (fs.existsSync(dirPath)) {
if (fs.existsSync(path.join(dirPath, "index.md"))) {
throw new Error(`Post already exists at ${dirPath}`);
}