瀏覽代碼

:art: https://github.com/siyuan-note/siyuan/issues/10547

Vanessa 1 年之前
父節點
當前提交
f87ac01461
共有 1 個文件被更改,包括 5 次插入3 次删除
  1. 5 3
      app/src/protyle/render/av/blockAttr.ts

+ 5 - 3
app/src/protyle/render/av/blockAttr.ts

@@ -114,9 +114,11 @@ export const genAVValueHTML = (value: IAVCellValue) => {
             break;
         case "relation":
             value?.relation?.contents?.forEach((item) => {
-                const rollupText = genAVRollupHTML(item);
-                if (rollupText) {
-                    html += rollupText + ", ";
+                if (item) {
+                    const rollupText = genAVRollupHTML(item);
+                    if (rollupText) {
+                        html += rollupText + ", ";
+                    }
                 }
             });
             if (html && html.endsWith(", ")) {