fixing chat leave bug