fixed ChatController is undefined error