fixed: 素材为空时的报错
This commit is contained in:
parent
ee0651fa36
commit
ac0ab41dcb
@ -69,8 +69,8 @@ function groupHasImageAndText(blocks: BlockContent[]) {
|
|||||||
// 验证分组数据是否合法
|
// 验证分组数据是否合法
|
||||||
function checkGroupsValid(groups: BlockContent[][]) {
|
function checkGroupsValid(groups: BlockContent[][]) {
|
||||||
if (groups.length == 1) return true;
|
if (groups.length == 1) return true;
|
||||||
for (const group of groups) {
|
for (let index = 1;index< groups.length; index ++) {
|
||||||
if(!groupHasImageAndText(group)) return false;
|
if(!groupHasImageAndText(groups[index])) return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user