| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent c676e52 commit 11e9789
2 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -270,14 +270,14 @@ function _disconnect(primaryInitiated) { | |||
| 270 | 270 | } | |
| 271 | 271 | } | |
| 272 | 272 | ||
| 273 | - handles.forEach((handle) => { | ||
| 273 | + for (const handle of handles.values()) { | ||
| 274 | 274 | waitingCount++; | |
| 275 | 275 | ||
| 276 | 276 | if (handle[owner_symbol]) | |
| 277 | 277 | handle[owner_symbol].close(checkWaitingCount); | |
| 278 | 278 | else | |
| 279 | 279 | handle.close(checkWaitingCount); | |
| 280 | - }); | ||
| 280 | + } | ||
| 281 | 281 | ||
| 282 | 282 | handles.clear(); | |
| 283 | 283 | checkWaitingCount(); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -152,10 +152,10 @@ function removeWorker(worker) { | |||
| 152 | 152 | function removeHandlesForWorker(worker) { | |
| 153 | 153 | assert(worker); | |
| 154 | 154 | ||
| 155 | - handles.forEach((handle, key) => { | ||
| 155 | + for (const { 0: key, 1: handle } of handles) { | ||
| 156 | 156 | if (handle.remove(worker)) | |
| 157 | 157 | handles.delete(key); | |
| 158 | - }); | ||
| 158 | + } | ||
| 159 | 159 | } | |
| 160 | 160 | ||
| 161 | 161 | cluster.fork = function(env) { | |
| Back | FazBrowse Home | New Git URL |
0 commit comments