forked from CFC-Servers/cfc_chat_transit
Guard against empty team
This commit is contained in:
parent
fc11cc59bc
commit
3d2063875e
@ -64,9 +64,9 @@ ChatTransit.GetRankColor = (ply) =>
|
|||||||
groupName = user and user.group or "user"
|
groupName = user and user.group or "user"
|
||||||
|
|
||||||
team = ULib.ucl.groups[groupName].team
|
team = ULib.ucl.groups[groupName].team
|
||||||
teamColor = "#{team.color_red} #{team.color_green} #{team.color_blue} 255"
|
|
||||||
|
|
||||||
return teamColor
|
return "#{team.color_red} #{team.color_green} #{team.color_blue} 255" if team
|
||||||
|
return "255 255 0 255"
|
||||||
|
|
||||||
ChatTransit.guard = (f, delay) -> (...) ->
|
ChatTransit.guard = (f, delay) -> (...) ->
|
||||||
args = {...}
|
args = {...}
|
||||||
|
Loading…
Reference in New Issue
Block a user