mirror of
https://github.com/discourse/discourse.git
synced 2025-02-10 13:24:55 +00:00
This commit addresses issues around starting new uploads in a composer etc. when one or more uploads are already processing or uploading. There were a couple of issues: 1. When all preprocessors were complete, we were not resetting `completeProcessing` to 0, which meant that `needProcessing` would never match `completeProcessing` if a new upload was started. 2. We were relying on the uppy "complete" event which is supposed to fire when all uploads are complete, but this doesn't seem to take into account new uploads that are added. Instead now we can rely on our own `inProgressUploads` tracker, and consider all uploads complete when there are no `inProgressUploads` in flight