Add a msg_id to a message if it does not have one already