bugfix: set_state updated state if not changed