Fixed a major bug when chatting.