added condition for the first added chat message