Load in the right order

This commit is contained in:
j433866 2019-04-04 13:14:45 +01:00
parent 76da287cca
commit 0804647441

View File

@ -296,7 +296,8 @@ class InputWaiter {
if (this.pendingFiles.length > 0) { if (this.pendingFiles.length > 0) {
log.debug("Loading file completed. Loading next file."); log.debug("Loading file completed. Loading next file.");
const nextFile = this.pendingFiles.pop(); const nextFile = this.pendingFiles[0];
this.pendingFiles.splice(0, 1);
currentWorker.inputNum = nextFile.inputNum; currentWorker.inputNum = nextFile.inputNum;
currentWorker.worker.postMessage({ currentWorker.worker.postMessage({
file: nextFile.file, file: nextFile.file,