Function frc46_token::token::validate_amount_with_granularity
source ยท pub fn validate_amount_with_granularity<'a>(
a: &'a TokenAmount,
name: &'static str,
granularity: u64,
) -> Result<&'a TokenAmount, TokenError>
Expand description
Validates that a token amount for burning/transfer/minting is non-negative, and an integer multiple of granularity.
Returns the argument, or an error.