Skip to content

Commit ad13760

Browse files
authored
fix: waitForRequestIdle locked (#17982)
1 parent 943ece1 commit ad13760

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

packages/vite/src/node/server/index.ts

+4-4
Original file line numberDiff line numberDiff line change
@@ -1251,15 +1251,15 @@ function setupOnCrawlEnd(onCrawlEnd: () => void): CrawlEndFinder {
12511251
if (ignoredId) {
12521252
seenIds.add(ignoredId)
12531253
markIdAsDone(ignoredId)
1254+
} else {
1255+
checkIfCrawlEndAfterTimeout()
12541256
}
12551257
return onCrawlEndPromiseWithResolvers.promise
12561258
}
12571259

12581260
function markIdAsDone(id: string): void {
1259-
if (registeredIds.has(id)) {
1260-
registeredIds.delete(id)
1261-
checkIfCrawlEndAfterTimeout()
1262-
}
1261+
registeredIds.delete(id)
1262+
checkIfCrawlEndAfterTimeout()
12631263
}
12641264

12651265
function checkIfCrawlEndAfterTimeout() {

0 commit comments

Comments
 (0)