Fix double bidding and connection reset problem.
Some checks are pending
lint / build (3.12) (push) Waiting to run

Close #165
This commit is contained in:
gerlofvanek 2024-11-22 21:08:19 +01:00 committed by tecnovert
parent d417a46e67
commit bebbba49ff

View file

@ -659,20 +659,13 @@ def page_offer(self, url_split, post_string):
extra_options=extra_options, extra_options=extra_options,
).hex() ).hex()
sent_bid_id = swap_client.postBid(
offer_id,
amount_from,
addr_send_from=addr_from,
extra_options=extra_options,
).hex()
if debugind > -1: if debugind > -1:
swap_client.setBidDebugInd(bytes.fromhex(sent_bid_id), debugind) swap_client.setBidDebugInd(bytes.fromhex(sent_bid_id), debugind)
self.send_response(302) self.send_response(302)
self.send_header("Location", f"/bid/{sent_bid_id}") self.send_header("Location", f"/bid/{sent_bid_id}")
self.end_headers self.end_headers()
return bytes return bytes()
except Exception as ex: except Exception as ex:
if self.server.swap_client.debug is True: if self.server.swap_client.debug is True: