문제

I have a web-chat application with group-chat. Now I can invite other users to my room, I can listen to invitations and I can decline an invitation, but for some reason, when a user declines my invitation, it doesn't trigger my onDecline method. Here's the part where I add the handler:

connection.addHandler(onDecline, Strophe.NS.MUC_USER);

//(Strophe.NS.MUC_USER = http://jabber.org/protocol/muc#user)

I get the following XML when the user declines:

<body xmlns="http://jabber.org/protocol/httpbind">
   <message xmlns="jabber:client" from="qvxuceluy@conference.127.0.0.1" to="hampel.elod_reea.net@127.0.0.1">
      <x xmlns="http://jabber.org/protocol/muc#user">
         <decline from="40756382284@127.0.0.1">
            <reason>Busy!</reason>
         </decline>
      </x>
   </message>
</body>
도움이 되었습니까?

해결책

Your message handler might be intercepting it. Make sure your message handler has "groupchat" or "chat" for the type (onMessage, null, 'message', 'chat'). Or you can handle it through your message handler.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top