Skip to content

Commit 7b7561b

Browse files
authored
Merge branch 'mainnet-beta' into master
2 parents 7bb0cf5 + ee4283a commit 7b7561b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/swift_server.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ pub async fn process_order(
253253

254254
if market
255255
.as_ref()
256-
.is_ok_and(|m| m.status == MarketStatus::Delisted)
256+
.is_ok_and(|m| matches!(m.status, MarketStatus::Delisted | MarketStatus::Settlement))
257257
{
258258
return Err((
259259
axum::http::StatusCode::BAD_REQUEST,
@@ -433,7 +433,9 @@ pub async fn deposit_trade(
433433
}
434434
let mut has_place_ix = false;
435435
for ix in req.deposit_tx.message.instructions() {
436-
if &ix.data[..8] == drift_idl::instructions::PlaceSignedMsgTakerOrder::DISCRIMINATOR {
436+
if ix.data.len() > 8
437+
&& &ix.data[..8] == drift_idl::instructions::PlaceSignedMsgTakerOrder::DISCRIMINATOR
438+
{
437439
has_place_ix = true;
438440
}
439441
}

0 commit comments

Comments
 (0)