updates, saving state