Skip to content

Commit 0bb4da5

Browse files
committed
fix: avoid to use concurrent uploads because break the count in the backend
1 parent 85ffe1a commit 0bb4da5

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/job-client.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -160,17 +160,17 @@ class JobClient{
160160
).then(
161161
(openJob)=>{
162162
job = openJob;
163-
const inputPromises = [];
163+
let inputPomise = Promise.resolve(openJob);
164164
Object.keys(fileSources).forEach(
165165
inputItemKey => {
166166
Object.keys(fileSources[inputItemKey]).forEach(
167167
dataItemKey => {
168-
inputPromises.push(this.appendInput(openJob, inputItemKey, dataItemKey, fileSources[inputItemKey][dataItemKey]));
168+
inputPomise = inputPomise.then( () => this.appendInput(openJob, inputItemKey, dataItemKey, fileSources[inputItemKey][dataItemKey]) );
169169
}
170170
);
171171
}
172172
);
173-
return Promise.all(inputPromises);
173+
return inputPomise;
174174
}
175175
).then(
176176
(submitResults)=>{

0 commit comments

Comments
 (0)