cleanup
Signed-off-by: microwavedcola1 <microwavedcola@gmail.com>
This commit is contained in:
parent
baf4b255c8
commit
de0ce5ad8f
|
@ -36,8 +36,8 @@ impl<'a> Book<'a> {
|
||||||
asks_ai: &'a AccountInfo,
|
asks_ai: &'a AccountInfo,
|
||||||
perp_market: &PerpMarket,
|
perp_market: &PerpMarket,
|
||||||
) -> std::result::Result<Self, Error> {
|
) -> std::result::Result<Self, Error> {
|
||||||
require!(bids_ai.key == &perp_market.bids, MangoError::SomeError); // MangoErrorCode::InvalidAccount
|
require!(bids_ai.key == &perp_market.bids, MangoError::SomeError);
|
||||||
require!(asks_ai.key == &perp_market.asks, MangoError::SomeError); // MangoErrorCode::InvalidAccount
|
require!(asks_ai.key == &perp_market.asks, MangoError::SomeError);
|
||||||
Ok(Self {
|
Ok(Self {
|
||||||
bids: BookSide::load_mut_checked(bids_ai, perp_market)?,
|
bids: BookSide::load_mut_checked(bids_ai, perp_market)?,
|
||||||
asks: BookSide::load_mut_checked(asks_ai, perp_market)?,
|
asks: BookSide::load_mut_checked(asks_ai, perp_market)?,
|
||||||
|
|
Loading…
Reference in New Issue