Skip to content

Commit

Permalink
Merge pull request #2548 from get10101/fix/race-condition-on-order-up…
Browse files Browse the repository at this point in the history
…dates

fix: Set order to open before the market order is posted
  • Loading branch information
holzeis authored May 16, 2024
2 parents 7ed3b26 + a4e20e5 commit be950c2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions mobile/native/src/trade/order/handler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ pub async fn submit_order_internal(
let url = Url::parse(&url).expect("correct URL");
let orderbook_client = OrderbookClient::new(url);

set_order_to_open_and_update_ui(order.id).map_err(SubmitOrderError::Storage)?;
if let Err(err) = orderbook_client
.post_new_market_order(order.clone().into(), channel_opening_params)
.await
Expand Down

0 comments on commit be950c2

Please sign in to comment.