@@ -15,12 +15,12 @@ export class StreamConnection {
1515 public streamId : string
1616 private queue : { transaction : Transaction } [ ] = [ ]
1717 private queueTimer : Timer = new Timer ( )
18- private callListener : ( listenerId : string , params ?: any [ ] ) => any [ ]
18+ private callListener : ( listenerId : string , params ?: any [ ] ) => void
1919 private connectionProgress : Transaction | null = null
2020 private disconnectionProgress : Transaction | null = null
2121 private XAPI : XAPI
2222
23- constructor ( url : string , session : string , callListener : ( listenerId : string , params ?: any [ ] ) => any [ ] , streamId : string , socketId : string , XAPI : XAPI ) {
23+ constructor ( url : string , session : string , callListener : ( listenerId : string , params ?: any [ ] ) => void , streamId : string , socketId : string , XAPI : XAPI ) {
2424 this . session = session
2525 this . socketId = socketId
2626 this . streamId = streamId
@@ -52,11 +52,7 @@ export class StreamConnection {
5252 const message = JSON . parse ( json . toString ( ) . trim ( ) )
5353 this . XAPI . counter . count ( [ 'data' , 'StreamConnection' , 'incomingData' ] , json . length )
5454
55- try {
56- this . callListener ( `command_${ message . command } ` , [ message . data , new Time ( ) , json , streamId ] )
57- } catch ( e ) {
58- console . error ( e )
59- }
55+ this . callListener ( `command_${ message . command } ` , [ message . data , new Time ( ) , json , streamId ] )
6056 } catch ( e ) {
6157 this . XAPI . counter . count ( [ 'error' , 'StreamConnection' , 'handleMessage' ] )
6258 this . callListener ( `handleMessage` , [ { error : e , time : new Time ( ) , json, streamId} ] )
0 commit comments