Skip to content

Commit

Permalink
fix: not executing db upgrades in the right order
Browse files Browse the repository at this point in the history
  • Loading branch information
arthurgeron committed Oct 16, 2024
1 parent defa8ff commit 9daf4df
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/app/src/systems/Core/utils/databaseVersioning.ts
Original file line number Diff line number Diff line change
Expand Up @@ -209,12 +209,12 @@ export const applyDbVersioning = (db: Dexie) => {
.first();

// De-select all networks
networks.each((_, { primaryKey }) => {
networks.update(primaryKey, { isSelected: false });
await networks.each(async (_, { primaryKey }) => {
await networks.update(primaryKey, { isSelected: false });
});

if (network) {
networks.update(network.id, { isSelected: true });
await networks.update(network.id, { isSelected: true });
return;
}

Expand Down

0 comments on commit 9daf4df

Please sign in to comment.