mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-02-15 14:40:05 +01:00
Core/Misc: ASSERT() cleanup
Move some functions calls out of ASSERT() calls. ASSERT() should only apply checks without modifying any object and without having any side effect.
(cherry picked from commit 572eab1c35)
This commit is contained in:
@@ -169,7 +169,8 @@ bool Group::Create(Player* leader)
|
||||
|
||||
Group::ConvertLeaderInstancesToGroup(leader, this, false);
|
||||
|
||||
ASSERT(AddMember(leader)); // If the leader can't be added to a new group because it appears full, something is clearly wrong.
|
||||
bool addMemberResult = AddMember(leader);
|
||||
ASSERT(addMemberResult); // If the leader can't be added to a new group because it appears full, something is clearly wrong.
|
||||
}
|
||||
else if (!AddMember(leader))
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user