Skip to content

Commit

Permalink
Avoid calling _advanceReadiness() too many times in dropInstance()
Browse files Browse the repository at this point in the history
By reading the code, I come to conclusion that _advanceReadiness() should be called exactly as many times as _deferReadiness(), per dbContext.
But in dropInstance() it is called for each forage of the dbContext.
  • Loading branch information
duzun committed Aug 14, 2021
1 parent c1cc34f commit bafe9d0
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/drivers/indexeddb.js
Original file line number Diff line number Diff line change
Expand Up @@ -1007,6 +1007,7 @@ function dropInstance(options, callback) {
for (var i = 0; i < forages.length; i++) {
const forage = forages[i];
_advanceReadiness(forage._dbInfo);
break;
}
})
.catch(err => {
Expand Down

0 comments on commit bafe9d0

Please sign in to comment.