pub fn parse_fee(value: Option<&str>, currency: Currency) -> Result<Money>
Expand description
Converts a textual fee amount into a Money
value.
OKX represents charges as positive numbers but they reduce the account balance, hence the value is negated.
ยงErrors
Returns an error if the fee cannot be parsed into f64
or fails internal
validation in Money::new_checked
.