diff --git a/src/libs/migrateOnyx.ts b/src/libs/migrateOnyx.ts index 97e698790d81..1202275067a5 100644 --- a/src/libs/migrateOnyx.ts +++ b/src/libs/migrateOnyx.ts @@ -15,14 +15,12 @@ export default function (): Promise { // Reduce all promises down to a single promise. All promises run in a linear fashion, waiting for the // previous promise to finish before moving onto the next one. /* eslint-disable arrow-body-style */ - migrationPromises.reduce( - (previousPromise, migrationPromise) => { + migrationPromises + .reduce((previousPromise, migrationPromise) => { return previousPromise.then(() => { return migrationPromise(); }); - }, - Promise.resolve(), - ) + }, Promise.resolve()) // Once all migrations are done, resolve the main promise .then(() => {