Don't send events after window is gone

This commit is contained in:
Thomas Nordquist
2019-01-14 17:12:46 +01:00
parent 7c72344174
commit d8c8799406

View File

@@ -28,8 +28,10 @@ class IpcMainEventBus implements EventBusInterface {
}
public emit<MessageType>(event: Event<MessageType>, msg: MessageType) {
if (!this.client.isDestroyed()) {
this.client.send(event.topic, msg)
}
}
}
class IpcRendererEventBus implements EventBusInterface {