fixed read of state