(err, errback)
| 525 | } |
| 526 | |
| 527 | function onError(err, errback) { |
| 528 | var ids = err.requireModules, |
| 529 | notified = false; |
| 530 | |
| 531 | if (errback) { |
| 532 | errback(err); |
| 533 | } else { |
| 534 | each(ids, function (id) { |
| 535 | var mod = getOwn(registry, id); |
| 536 | if (mod) { |
| 537 | //Set error on module, so it skips timeout checks. |
| 538 | mod.error = err; |
| 539 | if (mod.events.error) { |
| 540 | notified = true; |
| 541 | mod.emit('error', err); |
| 542 | } |
| 543 | } |
| 544 | }); |
| 545 | |
| 546 | if (!notified) { |
| 547 | req.onError(err); |
| 548 | } |
| 549 | } |
| 550 | } |
| 551 | |
| 552 | /** |
| 553 | * Internal method to transfer globalQueue items to this context's |
no test coverage detected