Fix toValue