Skip to content

Conversation

@crispheaney
Copy link
Member

No description provided.

let markets = &markets.load()?;
let user_positions = &mut user_positions.load_mut()?;
let funding_payment_history = &mut funding_payment_history.load_mut()?;
settle_funding_payment(user, user_positions, markets, funding_payment_history, now)?;
Copy link
Member

@0xbigz 0xbigz Apr 13, 2022

Choose a reason for hiding this comment

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

would it be better to settle funding and then set the collateral_before?

think it more accurately reflects the user collateral just before deposit

let markets = &markets.load()?;
let user_positions = &mut user_positions.load_mut()?;
let funding_payment_history = &mut funding_payment_history.load_mut()?;
settle_funding_payment(user, user_positions, markets, funding_payment_history, now)?;
Copy link
Member

Choose a reason for hiding this comment

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

here as well for collateral_before

@@ -0,0 +1,27 @@
use anchor_lang::prelude::*;

pub const UNINITIALIZED_NAME: [u8; 32] = [32; 32];
Copy link
Member

Choose a reason for hiding this comment

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

is this just all spaces? can emojis be used in the name?

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