Dry up the state checking logic