chore(types): remove unnecessary assertions (#4168)

This commit is contained in:
王嘉欣 2021-07-22 03:55:31 +08:00 committed by GitHub
parent 9c931d8154
commit 36ae23d27e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -130,7 +130,7 @@ function queueCb(
!activeQueue || !activeQueue ||
!activeQueue.includes( !activeQueue.includes(
cb, cb,
(cb as SchedulerJob).allowRecurse ? index + 1 : index cb.allowRecurse ? index + 1 : index
) )
) { ) {
pendingQueue.push(cb) pendingQueue.push(cb)
@ -221,7 +221,7 @@ export function flushPostFlushCbs(seen?: CountMap) {
} }
const getId = (job: SchedulerJob): number => const getId = (job: SchedulerJob): number =>
job.id == null ? Infinity : job.id! job.id == null ? Infinity : job.id
function flushJobs(seen?: CountMap) { function flushJobs(seen?: CountMap) {
isFlushPending = false isFlushPending = false