by spheroidmethod · 4y ago · 0 comments
But it was relatively easy to prevent problems with this. When the user clicked the button to place the order, we sent along the expected order total, the expected item IDs to purchase, the expected tax, etc. In the backend, one of the last validation step before the order was finalized was just to compare the final order details against those expected values. If there were any differences, the order was rejected with an error message to try again. There were then monitors on these types of errors which would go off if there was a higher-than-normal frequency of these sorts of errors, so we could track down any bugs causing price discrepancies.
I'm kind of surprised that UberEats doesn't seem to have a similar validation step.
I don't see any reason from the post to believe this kind of race condition is what happened here.
Uber's CS says the promotional code used was not valid for this restaurant, but presumably the app accepted it anyway. That's also likely a validation error, but of a different class.
> …but presumably the app accepted it anyway…
Not a lawyer, but I’m pretty sure things like this would constitute a contract. Of course, whether there’s squirrelly language in the Terms of Service is another question…
EDIT: formatting
That's what OP was saying.