mostro icon indicating copy to clipboard operation
mostro copied to clipboard

A user can take a sell order multiple times in status waiting-buyer-invoice

Open Catrya opened this issue 8 months ago • 0 comments

A user can take a sell order multiple times while in status waiting-buyer-invoice ; each time they do so, a new event 38383 will be published.

If they take a range order and choose a fiat amount ¨X¨, when they take it again, even if they choose a different fiat amount, Mostro will ask them to send an invoice for the amount of Sats equivalent to ¨X¨.

I think Mostro updates the fiat amount correctly bc publishes an order discounting that amount of fiat when the trade ends. However, it does not update the amount of Sats each time the buyer takes the order.

Preventing a user from taking the same order twice in the "waiting-buyer-invoice" status helps avoid the other issue.

Example. sell order 100-700 cup 1st time taken: 500 cup (2219 sats) Captura desde 2024-06-25 12-49-21

2nd time taken: 300 cup Captura desde 2024-06-25 12-50-44

3rd time taken: 700 cup Captura desde 2024-06-25 12-51-47

Catrya avatar Jun 25 '24 16:06 Catrya