Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Set quantity to zero when initiation order view with open position #2468

Merged
merged 1 commit into from Apr 25, 2024

Conversation

holzeis
Copy link
Contributor

@holzeis holzeis commented Apr 24, 2024

If we don't have a position we default the quantity to the max quantity. If we have an open position we default the quantity to zero because the contracts will be defaulted to the open quantity.

The behaviour should be that in case of an open position the default contracts on the opposite direction is to close the position.

fixes #2465

If we don't have a position we default the quantity to the max quantity. If we have an open position we default the quantity to zero because the contracts will be defaulted to the open quantity.

The behaviour should be that in case of an open position the default contracts on the opposite direction is to close the position.
@holzeis holzeis self-assigned this Apr 24, 2024
@holzeis holzeis enabled auto-merge April 24, 2024 17:38
@holzeis holzeis added this pull request to the merge queue Apr 24, 2024
Merged via the queue into main with commit 0bf215b Apr 25, 2024
23 checks passed
@holzeis holzeis deleted the fix/initial-margin-calculation branch April 25, 2024 00:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Margin is calculated from max quantity when initializing order view
2 participants