I am not sure if this is intentional but I noticed that presence subscription results in firing ContactChangeStatusEvent event. This seems not entirely correct, as subscription request does not really change contact status.
I am not even sure if this should trigger PresenceReceivedEvent as this is really subscription request. Perhaps it would be more efficient to have a separate SubscriptionReuqestEvent to be triggered for such packets.
Unknown commented 4 years ago
I implemented it. I also added one small thing: You can use typeAndShow() on any Presence? object to get contact status calculated from stanza type and field show.
I am not sure if this is intentional but I noticed that presence
subscription
results in firingContactChangeStatusEvent
event. This seems not entirely correct, as subscription request does not really change contact status.I am not even sure if this should trigger
PresenceReceivedEvent
as this is really subscription request. Perhaps it would be more efficient to have a separateSubscriptionReuqestEvent
to be triggered for such packets.