fixed initial chat code