This commit is contained in:
dy 2023-12-20 20:06:52 +08:00
parent 44be68a8ca
commit 97d1ddb142

View File

@ -18,7 +18,7 @@ export default async function (call: ApiCall<ReqReceive, ResReceive>) {
// 取奖励列表,判断是否有可领取奖励
let data = await G.mongodb.cEvent('pobinglibao').findOne({uid: call.uid, type: 'pobinglibao'})
let rec = data?.record?.[call.req.id].length
let rec = data?.record?.[call.req.id]?.length
if (rec && (rec >= 3 || data?.record?.[gift.id] == call.req.recId)) return call.errorCode(-3)
await PlayerFun.sendPrize(call, gift[call.req.recId]);