Delete leftover references to state