Skip to content

Commit

Permalink
Use round instead of floor
Browse files Browse the repository at this point in the history
  • Loading branch information
TimDiekmann committed Sep 27, 2024
1 parent 120de69 commit e8e57a2
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ fn float_multiple_of(lhs: f64, rhs: f64) -> bool {
return false;
}
let quotient = lhs / rhs;
(quotient - quotient.floor()).abs() < f64::EPSILON
(quotient - quotient.round()).abs() < f64::EPSILON
}

impl NumberSchema {
Expand Down

0 comments on commit e8e57a2

Please sign in to comment.