diff --git a/project/src/controllers/BotController.ts b/project/src/controllers/BotController.ts index d24a654f..270c2689 100644 --- a/project/src/controllers/BotController.ts +++ b/project/src/controllers/BotController.ts @@ -275,7 +275,7 @@ export class BotController } // Construct cache key - const cacheKey = `${requestedBot.Role}${requestedBot.Difficulty}`; + const cacheKey = `${botGenerationDetails.role}${botGenerationDetails.botDifficulty}`; // Check cache for bot using above key if (!this.botGenerationCacheService.cacheHasBotOfRole(cacheKey))