Closed 0xAnakin closed 1 year ago
Hey @0xAnakin, sorry for late response.
I think I've found it. Both shout.open()
, shout.send()
and shout.setMetadata()
methods return a code indicating whether the operation is successful or not. You can see what method can return which codes from the original libshout docs.
If disconnected, shout.send()
returns -2
which is nodeshout.ErrorTypes.NOCONNECT
. You can catch the disconnection event like this.
Yes I did the same thing after each send I'm checking if the data have been sent otherwise i fire an error event.
Is there a way to get notified when you get disconnected from the icecast server?