fix(runtime-core): ensure only skip unflushed job (#3406)

This commit is contained in:
edison 2021-03-25 23:13:35 +08:00 committed by GitHub
parent 49f4072c83
commit bf34e33c90
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -110,7 +110,7 @@ function queueFlush() {
export function invalidateJob(job: SchedulerJob) {
const i = queue.indexOf(job)
if (i > -1) {
if (i > flushIndex) {
queue.splice(i, 1)
}
}