Skip to content

Commit a007a49

Browse files
author
haiyan.lu
committed
fix(DocumentPendingService): 检查文件内容是否为空以防止构建失败
当文件内容为空时会导致构建失败,增加对fileItem.Content的空检查以避免此问题
1 parent 857e994 commit a007a49

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/KoalaWiki/KoalaWarehouse/DocumentPending/DocumentPendingService.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ public static async Task HandlePendingDocumentsAsync(List<DocumentCatalog> docum
6767
{
6868
var (catalog, fileItem, files) = await completedTask.ConfigureAwait(false);
6969

70-
if (fileItem == null)
70+
if (fileItem == null || string.IsNullOrEmpty(fileItem.Content))
7171
{
7272
// 构建失败
7373
Log.Logger.Error("处理仓库;{path} ,处理标题:{name} 失败:文件内容为空", path, catalog.Name);

0 commit comments

Comments
 (0)