Added onChatDisabled function