- Issue created by @GuillaumePacilly
- Merge request !11#3527889: check for existing completed payments only when processing payment → (Open) created by GuillaumePacilly
- 🇨🇭Switzerland berdir Switzerland
That's only correct if you have autocomplete enabled, otherwise they might be authorized only and that's the expected state.
I'm unsure how you end up with multiple payments, they are only created if at least in authorized state and there shouldn't be a need to do another then?
We just discussed kind of the opposite, that we should drop the return FALSE and return the payment we have, possibly depending on the state and autocomplete setting. That should in my opinion remove the need for those long sleep() calls on notify, because the loadForUpdate() should ensure that it will only have to wait as long as necessary and it's not a big deal then if notify goes first.