Closed AnD010 closed 3 years ago
Hi,
This doesn't look like a beams issue but more rather an issue with the channels sdk.
It doesn't look like you're binding with the correct listener.
Either you can have one PresenceChannelEventListener and provide a list of the event names you're interested in as per https://github.com/pusher/pusher-websocket-java/blob/master/src/main/java/com/pusher/client/Pusher.java#L345
e.g.
channel = pusher.subscribePresence(channelName, presenceChannelEventListener, "event-two", "event-one");
Or, you can bind and listen for just the event info with a SubscriptionEventListener e.g.
channel.bind("my-event", new SubscriptionEventListener() {
@Override
public void onEvent(PusherEvent event) {
// todo
}
});
Additionally, you need only call unsubscribe
on the channel - you do not need to unbind from the events first - calling unsubscribe
will stop any events you're listening to come through too.
Does that make sense?
We haven't had a response here so I will close this out - comment with the requested information if you need this to remain open.
Hi...I have a ugly error when app come back from background.... When I detected that the app is going to background I do this
Then when 5-10 pass and the app come back from background, I mean, now the app is in foreground, then call
The app crash whit the following message
whats wrong in my code?? thanks