Skip to content

Commit

Permalink
Use base.Close() when event is canceled (#55)
Browse files Browse the repository at this point in the history
  • Loading branch information
CirnoV authored May 27, 2021
1 parent 1333456 commit 735a2c6
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions client/Source-Chat-Relay.sp
Original file line number Diff line number Diff line change
Expand Up @@ -551,7 +551,10 @@ public void HandlePackets(const char[] sBuffer, int iSize)
Call_Finish(aResult);

if (aResult >= Plugin_Handled)
{
base.Close();
return;
}

#if defined DEBUG
PrintToConsoleAll("====== Chat Message Packet =====");
Expand Down Expand Up @@ -587,7 +590,10 @@ public void HandlePackets(const char[] sBuffer, int iSize)
Call_Finish(aResult);

if (aResult >= Plugin_Handled)
{
base.Close();
return;
}

if (SupportsHexColor(g_evEngine))
CPrintToChatAll("{gold}[%s]{white}: {grey}%s", sEvent, sData);
Expand Down

0 comments on commit 735a2c6

Please sign in to comment.