Skip to content

Commit

Permalink
Extend transaction when disbanding groups to ensure synchronous execu…
Browse files Browse the repository at this point in the history
…tion.

Thanks to Chero.
  • Loading branch information
ratkosrb committed Nov 13, 2024
1 parent 1a41410 commit 3cd5496
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/game/Group/Group.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -623,7 +623,6 @@ void Group::Disband(bool hideDestroy, ObjectGuid initiator)
CharacterDatabase.BeginTransaction(m_Id);
CharacterDatabase.PExecute("DELETE FROM `groups` WHERE `group_id`='%u'", m_Id);
CharacterDatabase.PExecute("DELETE FROM `group_member` WHERE `group_id`='%u'", m_Id);
CharacterDatabase.CommitTransaction();

// transfer instance save to last player in dungeon
if (remainingPlayer)
Expand All @@ -641,6 +640,7 @@ void Group::Disband(bool hideDestroy, ObjectGuid initiator)
}

ResetInstances(INSTANCE_RESET_GROUP_DISBAND, nullptr);
CharacterDatabase.CommitTransaction();
}

_updateLeaderFlag(true);
Expand Down

0 comments on commit 3cd5496

Please sign in to comment.