I would call `appendMessage` before `messageIndex++`, and thus before `renderingOver` anyway