Default anticrash event text when given a non-string value

This commit is contained in:
legokidlogan 2021-10-09 11:26:30 -06:00 committed by Brandon Sturgeon
parent 06c2a7690a
commit 522ef63b5b

View File

@ -124,7 +124,12 @@ ChatTransit.PlayerDisconnected = (ply) =>
@WebSocket\write message
ChatTransit.AnticrashEvent = (eventText="Heavy lag detected!") =>
ChatTransit.AnticrashEvent = (eventText) =>
argType = type eventText
if argType ~= "string"
eventText = "Heavy lag detected!"
struct =
Type: "anticrash_event"
Data: