| 3643 | onRecoverableError("daemonClientConnected", jsEntry.exceptionTracker); |
| 3644 | return; |
| 3645 | } |
| 3646 | }); |
| 3647 | } |
| 3648 | |
| 3649 | void JavaScriptRuntime::daemonClientDisconnected(const Shared<IDaemonClient>& daemonClient) { |
| 3650 | dispatchOnJsThreadUnattributed([=](JavaScriptEntryParameters& jsEntry) { |
| 3651 | const auto& it = _daemonClients.find(daemonClient->getConnectionId()); |
| 3652 | if (it != _daemonClients.end()) { |
| 3653 | auto daemonClientJs = it->second; |
| 3654 | _daemonClients.erase(it); |
| 3655 | |
| 3656 | notifyDaemonClientEvent(DaemonClientEventTypeDisconnected, daemonClientJs.get(), JSValue(), jsEntry); |
| 3657 | if (!jsEntry.exceptionTracker) { |
| 3658 | onRecoverableError("daemonClientDisconnected", jsEntry.exceptionTracker); |
| 3659 | return; |
| 3660 | } |