Fix small bug on states