diff --git a/wardrobe/money/src/lib.rs b/wardrobe/money/src/lib.rs index 1543ecbfa..f496a37b1 100644 --- a/wardrobe/money/src/lib.rs +++ b/wardrobe/money/src/lib.rs @@ -150,12 +150,10 @@ impl SimpleConstraintChecker for SpendMoney { ConstraintCheckerError::OutputsExceedInputs ); - // Priority is based on how many token are burned - // Type stuff is kinda ugly. Maybe division would be better? let burned = total_input_value - total_output_value; + // Priority is based on how many token are burned // Just a saturated version of the burned amount. - // TODO can't I use saturating_into or something here instead of writing it myself? let priority = if burned < u64::max_value() as u128 { burned as u64 } else {