*Add getter for channel
This commit is contained in:
parent
baf0ac31e6
commit
b3a7c0b4e1
|
@ -56,8 +56,6 @@ export default class Peer {
|
|||
private _onclose: OnCloseBound;
|
||||
private _emulateWebsocket: boolean;
|
||||
|
||||
private _channel?: any;
|
||||
|
||||
constructor({
|
||||
proxy,
|
||||
peer,
|
||||
|
@ -78,6 +76,12 @@ export default class Peer {
|
|||
this._emulateWebsocket = emulateWebsocket;
|
||||
}
|
||||
|
||||
private _channel?: any;
|
||||
|
||||
get channel(): any {
|
||||
return this._channel;
|
||||
}
|
||||
|
||||
async init() {
|
||||
const write = async (data: any, cb: Function) => {
|
||||
pipe.send(data);
|
||||
|
|
Loading…
Reference in New Issue