From 584d4e032e9e2ff44048962d48473a92d32bb5c9 Mon Sep 17 00:00:00 2001 From: Oliver Gugger Date: Fri, 14 Aug 2020 09:32:27 +0200 Subject: [PATCH] rpcserver: allow orders to be submitted in StatePendingBatch --- rpcserver.go | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/rpcserver.go b/rpcserver.go index 46c00e2..06ef4c5 100644 --- a/rpcserver.go +++ b/rpcserver.go @@ -1319,11 +1319,13 @@ func (s *rpcServer) SubmitOrder(ctx context.Context, } // We'll only allow orders for accounts that present in an open state, - // or have a pending update. On the server-side if we have a pending - // update we won't be matched, but this lets us place our orders early - // so we can join the earliest available batch. + // or have a pending update or batch. On the server-side if we have a + // pending update we won't be matched, but this lets us place our orders + // early so we can join the earliest available batch. switch acct.State { - case account.StateOpen, account.StatePendingUpdate: + case account.StateOpen, account.StatePendingUpdate, + account.StatePendingBatch: + break default: