Changeset 9874

Show
Ignore:
Timestamp:
07/02/08 12:48:15 (5 months ago)
Author:
js
Message:

XEP-0184 uses the new caps-checking way now.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/src/common/connection.py

    r9841 r9874  
    11021102                                user_nick) 
    11031103 
     1104                # TODO: We might want to write a function so we don't need to 
     1105                #       reproduce that ugly if somewhere else. 
     1106                if resource: 
     1107                        contact = gajim.contacts.get_contact(self.name, jid, 
     1108                                resource) 
     1109                else: 
     1110                        contact = gajim.contacts. \ 
     1111                                get_contact_with_highest_priority(self.name, 
     1112                                jid) 
     1113 
    11041114                # chatstates - if peer supports xep85 or xep22, send chatstates 
    11051115                # please note that the only valid tag inside a message containing a <body> 
     
    11241134 
    11251135                # XEP-0184 
    1126                 if resource: 
    1127                         contact = gajim.contacts.get_contact(self.name, jid, 
    1128                                 resource) 
    1129                 else: 
    1130                         contact = gajim.contacts. \ 
    1131                                 get_contact_with_highest_priority(self.name, 
    1132                                 jid) 
    11331136                if msgtxt and gajim.config.get_per('accounts', self.name, 
    1134                 'request_receipt') and common.xmpp.NS_RECEIPTS in \ 
    1135                 gajim.capscache[(contact.caps_hash_method, 
    1136                 contact.caps_hash)].features: 
     1137                'request_receipt') and gajim.capscache.is_supported(contact, 
     1138                common.xmpp.NS_RECEIPTS: 
    11371139                        msg_iq.setTag('request', 
    11381140                                namespace=common.xmpp.NS_RECEIPTS)