Skip to content

Commit 255ea82

Browse files
author
BuildTools
committed
fix(#1099): hexo server error when changing the config
1 parent 4d42d9d commit 255ea82

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

lib/plugins/processor/post.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,12 @@ function parseFilename(config, path) {
206206
const data = permalink.parse(path);
207207

208208
if (data) {
209-
return data;
209+
if (data.title !== undefined) {
210+
return data;
211+
}
212+
return Object.assign(data, {
213+
title: slugize(path)
214+
});
210215
}
211216

212217
return {

0 commit comments

Comments
 (0)