|
|
@ -35,6 +35,7 @@ export default class TorrentClientIpc |
|
|
|
*/ |
|
|
|
public boot() { |
|
|
|
return new Promise<void>((resolve, reject) => { |
|
|
|
console.log(process.env["TORRENT_CLIENT_IPC_SOCKET"]); |
|
|
|
ipc.connectTo("torrent_client", process.env["TORRENT_CLIENT_IPC_SOCKET"], () => { |
|
|
|
this.socket = ipc.of["torrent_client"]; |
|
|
|
this.installSocketEventHandlers(this.socket); |
|
|
@ -60,7 +61,7 @@ export default class TorrentClientIpc |
|
|
|
// Socket Event Handlers -----------------------------------------------------------------------
|
|
|
|
|
|
|
|
protected onConnect() { |
|
|
|
if (this.__isConnected) { |
|
|
|
if (!this.__isConnected) { |
|
|
|
console.log("IPC: Connection established"); |
|
|
|
} |
|
|
|
this.__isConnected = true; |
|
|
|