2889029b70
* Extract reorder logic into function * Save download queue everytime a download was finished The download queue was never saved after a download was finished. This caused finished download to be restored on a server start, which caused unnecessary "downloads" which most of the time would just finish immediately since the pages were still in the cache * Wait for download queue save process to be finished Since multiple downloaders could be finished at the same time, the download queue should be saved synchronously * Remove unnecessary download queue save trigger This gets called everytime a downloader finished downloading all chapters of its source. Since the queue is now saved everytime a download is finished, this is trigger is not needed anymore