From 9ab0b40854089c2d0baa1d1f7e1207f54187da7c Mon Sep 17 00:00:00 2001 From: Dev Date: Fri, 18 Oct 2024 19:10:28 +0100 Subject: [PATCH] Fixed botgen failing --- project/src/helpers/BotHelper.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project/src/helpers/BotHelper.ts b/project/src/helpers/BotHelper.ts index 7899092d..44a55852 100644 --- a/project/src/helpers/BotHelper.ts +++ b/project/src/helpers/BotHelper.ts @@ -177,7 +177,7 @@ export class BotHelper { */ public getPmcNicknameOfMaxLength(maxLength: number, side?: string): string { const randomType = side ? side : this.randomUtil.getInt(0, 1) === 0 ? "usec" : "bear"; - const allNames = this.databaseService.getBots().types[randomType].firstName; + const allNames = this.databaseService.getBots().types[randomType.toLowerCase()].firstName; const filteredNames = allNames.filter((name) => name.length <= maxLength); if (filteredNames.length === 0) { this.logger.warning(