Rename count to numMessagesPerBatch

This commit is contained in:
Daniel Gasienica 2018-04-03 14:43:17 -04:00
parent 38ac9972e8
commit 12cdeee7ec
2 changed files with 37 additions and 13 deletions

View file

@ -90,12 +90,13 @@
storage.fetch();
const idleDetector = new IdleDetector();
idleDetector.on('idle', async () => {
const NUM_MESSAGES_PER_BATCH = 1;
const database = Migrations0DatabaseWithAttachmentData.getDatabase();
const batch = await MessageDataMigrator.processNextBatchWithoutIndex({
databaseName: database.name,
minDatabaseVersion: database.version,
numMessagesPerBatch: NUM_MESSAGES_PER_BATCH,
upgradeMessageSchema,
});
console.log('Upgrade message schema:', batch);