lob-java icon indicating copy to clipboard operation
lob-java copied to clipboard

Change `CheckEditable.amount` from `Float` to `Double`

Open mccormick-wooden opened this issue 1 year ago • 0 comments

Float too imprecise for this field, and when serialized the value can materially change:

jshell> 147480.18f
$1 ==> 147480.19

We should at least change the type to Double, though I would prefer to change this field to BigDecimal - let me know if that is workable (not sure why floating point types were originally chosen for this and understand there may be constraints I'm not aware of).

Fix attempted here: https://github.com/lob/lob-java/pull/345

mccormick-wooden avatar Nov 19 '24 22:11 mccormick-wooden