From 149a3c2e820b093b49fe898862f4043a6091372c Mon Sep 17 00:00:00 2001 From: Uleat Date: Tue, 12 Apr 2016 18:29:09 -0400 Subject: [PATCH] Would real 'Fix for BotDatabase::LoadBotGroupIDForLoadBotGroup() failures when more than one bot-group exists and requested bg is not primary in retrieval order' please stand up.. --- zone/bot_database.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/zone/bot_database.cpp b/zone/bot_database.cpp index c9c5b594d..416e0c304 100644 --- a/zone/bot_database.cpp +++ b/zone/bot_database.cpp @@ -2329,10 +2329,13 @@ bool BotDatabase::LoadBotGroupIDForLoadBotGroup(const uint32 owner_id, const std if (!results.RowCount()) return true; - auto row = results.begin(); - if (!group_name.compare(row[1])) - botgroup_id = atoi(row[0]); - + for (auto row = results.begin(); row != results.end(); ++row) { + if (!group_name.compare(row[1])) { + botgroup_id = atoi(row[0]); + break; + } + } + return true; }