From 7c2d93e87b9138918e35d8564d8385d2bd161317 Mon Sep 17 00:00:00 2001 From: Dev Date: Thu, 7 Dec 2023 20:07:46 +0000 Subject: [PATCH] Handle edge case when an item is missing a min/max stack size value --- project/src/generators/LootGenerator.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project/src/generators/LootGenerator.ts b/project/src/generators/LootGenerator.ts index b94df6c8..61092a72 100644 --- a/project/src/generators/LootGenerator.ts +++ b/project/src/generators/LootGenerator.ts @@ -209,7 +209,7 @@ export class LootGenerator max = options.itemStackLimits[item._id].max; } - return this.randomUtil.getInt(min, max); + return this.randomUtil.getInt(min ?? 1, max ?? 1); } /**