Skip to content

Conversation

@crispheaney
Copy link
Member

No description provided.

.safe_mul(LIQUIDATION_FEE_PRECISION_U128)?
.safe_div(oracle_price.cast::<u128>()?)?
.cast::<u32>()
.unwrap_or(u32::MAX);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why wouldnt we bubble up an casting error if cast fails? when would we expect the fee to be that high?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

true we can probably change this

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.

3 participants