local iIndex = nil |
local _, nGeneral = GetChannelName(1) |
local _, nTrade = GetChannelName(2) |
local _, nGuildRecruitment = GetChannelName(6) |
if nGuildRecruitment and nGuildRecruitment:match("^Guild") and (DirtyRecruit.PerPlayer.Spam == "all" or DirtyRecruit.PerPlayer.Spam == "recruit") then |
iIndex = 6 |
local _, nGuildRecruitment = GetChannelName(4) |
if nGuildRecruitment and nGuildRecruitment:match("^Guild") and (DirtyRecruit.PerPlayer.Spam == "all" or DirtyRecruit.PerPlayer.Spam == "guild") then |
iIndex = 4 |
elseif nTrade and nTrade:match("^Trade") and (DirtyRecruit.PerPlayer.Spam == "all" or DirtyRecruit.PerPlayer.Spam == "trade") then |
iIndex = 2 |
elseif nGeneral and nGeneral:match("^General") and (DirtyRecruit.PerPlayer.Spam == "all" or DirtyRecruit.PerPlayer.Spam == "general") then |