File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -1180,14 +1180,14 @@ fn verify_input_and_output_consistent_with_order(
11801180 Ok ( ( ) )
11811181}
11821182
1183- fn is_ratio_equal ( a : u64 , b : u64 , c : u64 , d : u64 ) -> bool {
1184- // a:b = c:d
1185- u128:: from ( a ) * u128:: from ( d ) == u128:: from ( b ) * u128:: from ( c )
1183+ fn is_ratio_equal ( from : u64 , fee : u64 , spent : u64 , fee_given : u64 ) -> bool {
1184+ // from:fee = spent:fee_given
1185+ u128:: from ( from ) * u128:: from ( fee_given ) == u128:: from ( fee ) * u128:: from ( spent )
11861186}
11871187
1188- fn is_ratio_greater_or_equal ( a : u64 , b : u64 , c : u64 , d : u64 ) -> bool {
1189- // a:b <= c:d
1190- u128:: from ( a ) * u128:: from ( d ) >= u128:: from ( b ) * u128:: from ( c )
1188+ fn is_ratio_greater_or_equal ( from : u64 , to : u64 , spent : u64 , output : u64 ) -> bool {
1189+ // from:to <= spent:output
1190+ u128:: from ( from ) * u128:: from ( output ) >= u128:: from ( to ) * u128:: from ( spent )
11911191}
11921192
11931193#[ cfg( test) ]
You can’t perform that action at this time.
0 commit comments