read receipts: fix group receipts

This commit is contained in:
DaZZZl 2016-02-19 18:12:47 +01:00
parent 4191c2864d
commit 2683b774f0

View file

@ -212,7 +212,7 @@ class Session(YowsupApp):
self.onPresenceUnavailable(number) self.onPresenceUnavailable(number)
def sendReadReceipts(self, buddy): def sendReadReceipts(self, buddy):
for _id, _from, participant in self.recvMsgIDs: for _id, _from, participant in self.recvMsgIDs:
if _from == (buddy + '@s.whatsapp.net'): if _from.split('@')[0] == buddy:
self.sendReceipt(_id, _from, 'read', participant) self.sendReceipt(_id, _from, 'read', participant)
self.recvMsgIDs.remove((_id, _from, participant)) self.recvMsgIDs.remove((_id, _from, participant))
self.logger.debug("Send read receipt to %s (ID: %s)", _from, _id) self.logger.debug("Send read receipt to %s (ID: %s)", _from, _id)