Skip to content

Commit

Permalink
flash -> flush
Browse files Browse the repository at this point in the history
  • Loading branch information
kuboon authored Sep 19, 2021
1 parent 694136c commit 84f37dd
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ export default async function main(append = false, oldest_: Date, latest_: Date)
const builder = new BatchBuilder
const messageProcessor = await new MessageProcessor().await()
let tsRecord: Record<string, string> = {}
async function flashAndSave() {
async function flushAndSave() {
const batches = builder.flush()
if (batches.length == 0) return
await gSheet.batchUpdate(batches).catch(e => {
Expand Down Expand Up @@ -84,9 +84,9 @@ export default async function main(append = false, oldest_: Date, latest_: Date)
if (estimate > 4000 && (!next || !next.thread_ts)) {
process.stdout.write('.')
tsRecord[c.channel_id] = msg.ts!
await flashAndSave()
await flushAndSave()
}
}
}
await flashAndSave()
await flushAndSave()
}

0 comments on commit 84f37dd

Please sign in to comment.