Function sentry::spender::fee::calculate_fee
source · pub fn calculate_fee(
(_earner, payout): (Address, UnifiedNum),
validator: &ValidatorDesc
) -> Result<UnifiedNum, DomainError>
Expand description
Calculates the fee for a given payout of the specified validator This function will return None if the provided validator is not part of the Campaign / Channel In the case of overflow when calculating the payout, an error will be returned