Ah. I was confused by the method name. Toggle usually means it turns it on and off, but your method only turns it on.
Did you test if the first message that triggers enable() shows up in the log?
There also seems to be a small mistake in your code. You ignore the values in listenInTheseChannels and only enable the chatlog when channelType == CHAT_CHANNEL_SAY.
Lua Code:
local function ChatLogger_ToggleChatLog(eventCode, channelType, fromName, text, isCustomerService, fromDisplayName)
if not playerInCyro and listenInTheseChannels[channelType] then
enable()
end
end
I am still not sure why this would be preferable to just turning the log on when the player logs in. :P