MOBILE-4470 workshop: Fix sync submission finishing without waiting
parent
4dd7b45678
commit
7cb9f1351c
|
@ -311,7 +311,7 @@ export class AddonModWorkshopSyncProvider extends CoreSyncBaseProvider<AddonModW
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
submissionActions.forEach(async (action) => {
|
await Promise.all(submissionActions.map(async (action) => {
|
||||||
submissionId = action.submissionid > 0 ? action.submissionid : submissionId;
|
submissionId = action.submissionid > 0 ? action.submissionid : submissionId;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
|
@ -397,7 +397,7 @@ export class AddonModWorkshopSyncProvider extends CoreSyncBaseProvider<AddonModW
|
||||||
siteId,
|
siteId,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
});
|
}));
|
||||||
|
|
||||||
if (discardError) {
|
if (discardError) {
|
||||||
// Submission was discarded, add a warning.
|
// Submission was discarded, add a warning.
|
||||||
|
|
Loading…
Reference in New Issue