On TradingService#getVolumeForOrder null check volume and use currency.base scale instead of USD scale #365
No reviewers
Labels
No labels
blocked
breaking
bug
dependencies
duplicate
enhancement
good first issue
help wanted
question
tech debt
testing
wontfix
No milestone
No project
No assignees
1 participant
Due date
No due date set.
Dependencies
No dependencies set.
Reference
scion/arbitrader!365
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "getVolumeFor-fix-rounding-issue-when-volume-is-null"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
In some cases the
volumemay be null and a NPE is thrown. To avoid that we do a null check before comparing the value ofvolume.If
volumeis null we fallback to getting the amount of currency base we have in our account. The issue is here, before this PR we would always use USD scale, even for crypto currencies.