Merge pull request #13877 from axules/bugfix/hot-poll-infinity

fix hot/poll, hot/condition, hot/only-dev-server infinity recursion
This commit is contained in:
Tobias Koppers 2021-08-02 12:10:09 +02:00 committed by GitHub
commit 1c1af83e12
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 3 deletions

View File

@ -13,7 +13,7 @@ if (module.hot) {
module.hot
.check()
.then(function (updatedModules) {
if (!updatedModules) {
if (!updatedModules || updatedModules.length === 0) {
log("warning", "[HMR] Cannot find update. Need to do a full reload!");
log(
"warning",

View File

@ -12,7 +12,7 @@ if (module.hot) {
module.hot
.check(true)
.then(function (updatedModules) {
if (!updatedModules) {
if (!updatedModules || updatedModules.length === 0) {
if (fromUpdate) log("info", "[HMR] Update applied.");
return;
}

View File

@ -9,7 +9,7 @@ if (module.hot) {
module.hot
.check()
.then(function (updatedModules) {
if (!updatedModules) {
if (!updatedModules || updatedModules.length === 0) {
if (fromUpdate) log("info", "[HMR] Update applied.");
else log("warning", "[HMR] Cannot find update.");
return;