only update url if state has actually be set