Skip to content

Commit

Permalink
Core/GroupHander: Check if player is in a group for `CMSG_REQUEST_PAR…
Browse files Browse the repository at this point in the history
…TY_MEMBER_STATS` before providing data. (TrinityCore#30084)
  • Loading branch information
heyitsbench authored Jul 16, 2024
1 parent 99d6afa commit 5e95f4d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/server/game/Handlers/GroupHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -911,7 +911,7 @@ void WorldSession::HandleRequestPartyMemberStatsOpcode(WorldPacket &recvData)
recvData >> Guid;

Player* player = ObjectAccessor::FindConnectedPlayer(Guid);
if (!player)
if (!player || !player->GetGroup() || !GetPlayer()->GetGroup() || (player->GetGroup() != GetPlayer()->GetGroup()))
{
WorldPacket data(SMSG_PARTY_MEMBER_STATS_FULL, 3+4+2);
data << uint8(0); // only for SMSG_PARTY_MEMBER_STATS_FULL, probably arena/bg related
Expand Down

0 comments on commit 5e95f4d

Please sign in to comment.