From 5b90d26a33caa3c334ad37496450dd2e92fa642f Mon Sep 17 00:00:00 2001 From: Kinglykrab <89047260+Kinglykrab@users.noreply.github.com> Date: Sun, 22 May 2022 22:31:03 -0400 Subject: [PATCH] [Bug Fix] Fix bot guild removal. (#2194) --- zone/bot.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/zone/bot.cpp b/zone/bot.cpp index 8e656617a..36e037b85 100644 --- a/zone/bot.cpp +++ b/zone/bot.cpp @@ -6788,7 +6788,7 @@ bool Bot::ProcessGuildRemoval(Client* guildOfficer, std::string botName) { if(guildOfficer && !botName.empty()) { Bot* botToUnGuild = entity_list.GetBotByBotName(botName); if(botToUnGuild) { - if (database.botdb.SaveGuildMembership(botToUnGuild->GetBotID(), 0, 0)) + if (database.botdb.DeleteGuildMembership(botToUnGuild->GetBotID())) Result = true; } else { uint32 ownerId = 0; @@ -6797,7 +6797,7 @@ bool Bot::ProcessGuildRemoval(Client* guildOfficer, std::string botName) { uint32 botId = 0; if (!database.botdb.LoadBotID(ownerId, botName, botId)) guildOfficer->Message(Chat::Red, "%s for '%s'", BotDatabase::fail::LoadBotID(), botName.c_str()); - if (botId && database.botdb.SaveGuildMembership(botId, 0, 0)) + if (botId && database.botdb.DeleteGuildMembership(botId)) Result = true; }