Revert "core: don't delete state data if id=nil [GH-2201]"

This reverts commit 1a780bf5b2fae0d5de3a522640640295d438ab68.

Conflicts:
	CHANGELOG.md