further fixes to state