🐞 fix(guild): 捐赠宝箱保护代码

This commit is contained in:
dingchaolin
2023-03-16 14:37:33 +08:00
parent 36c81751bd
commit 569aaf648c

View File

@@ -81,8 +81,8 @@ export function changeReceiveBoxIdByLvAndIndex(receiveBoxs: number[], donationLv
// 获取已领取箱子的index
let { index } = getArmyDonateBoxBaseById(boxId);
// 获取donationLv等级第index个箱子的id
let { id } = getArmyDonateBoxBaseByLvAndIndex(donationLv, index);
haveGotBoxIds.push(id);
let donateInfo = getArmyDonateBoxBaseByLvAndIndex(donationLv, index);
haveGotBoxIds.push(donateInfo ? donateInfo.id : 0);
});
return haveGotBoxIds;
}