主线:允许武将数组传空数组

This commit is contained in:
luying
2021-04-28 09:31:39 +08:00
parent 81a1e22919
commit 44f0316769

View File

@@ -63,7 +63,7 @@ export async function roleLevelup(roleId: string, kingExp: number, session: Back
export async function checkBattleHeroes(roleId: string, seqIds: Array<number>) {
let heroes: number[] = [];
let flag = true;
if (seqIds.length <= 0) flag = false;
// if (seqIds.length <= 0) flag = false;
const findHeroes = await HeroModel.findBySeqIdRange(seqIds, roleId);
if (findHeroes.length != seqIds.length) flag = false;
@@ -79,7 +79,7 @@ export async function checkBattleHeroes(roleId: string, seqIds: Array<number>) {
export async function checkBattleHeroesByHid(roleId: string, heroes: Array<number>) {
let flag = true;
if (heroes.length <= 0) flag = false;
// if (heroes.length <= 0) flag = false;
const findHeroes = await HeroModel.findByHidRange(heroes, roleId);
if (findHeroes.length != heroes.length) flag = false;