87 | @@ -87,6 +88,7 @@ std::vector<unsigned char> ParseHexO(const UniValue& o, std::string strKey);
88 | * @returns a CAmount if the various checks pass.
89 | */
90 | CAmount AmountFromValue(const UniValue& value, int decimals = 8);
91 | +util::Result<CAmount> AmountFromValueResult(const UniValue& value, int decimals = 8);
Not sure. There were previously two functions and there still are two functions now, with more code at the call sites. So I am not sure if this is an improvement. The only difference seems to be in the throw function, so in theory you could pass in a lambda that takes care of the throw, but I am not sure if this is worth it.
Updated to no additional code at call sites with logic still deduplicated to one place.