购买 E2E 定价边界建游失败时提前退出

- boundsGameId 为空时先记录失败再 process.exit(1),避免后续请求 /undefined 级联掩盖根因
This commit is contained in:
2026-10-07 14:10:14 +08:00
parent 9a653c8382
commit 3a0d275746
@@ -1474,6 +1474,9 @@ async function main() {
boundsGameCreated.status === 200 && Boolean(boundsGameId),
`status=${boundsGameCreated.status} gameId=${String(boundsGameId)}`,
);
// 建游失败时下面的 /my-games/undefined 与 /games/undefined/versions 会级联报错,
// 掩盖真正的根因;这里与其它脚本一致,先记录失败再退出。
if (!boundsGameId) process.exit(1);
// 单游戏作者视图把自有条目挂在 `data.game` 下(`versions` 在条目里,不在顶层)。
const countBoundsVersions = async () => {
const ownerEntry = await api(