messages-send: Don't send group skdistMsg to hosted id
This commit is contained in:
@@ -66,7 +66,7 @@ export const makeGroupsSocket = (config: SocketConfig) => {
|
||||
data[meta.id] = meta
|
||||
}
|
||||
}
|
||||
|
||||
// TODO: properly parse LID / PN DATA
|
||||
sock.ev.emit('groups.update', Object.values(data))
|
||||
|
||||
return data
|
||||
|
||||
@@ -43,6 +43,8 @@ import {
|
||||
getBinaryNodeChild,
|
||||
getBinaryNodeChildren,
|
||||
isJidGroup,
|
||||
isJidHostedLidUser,
|
||||
isJidHostedPnUser,
|
||||
isLidUser,
|
||||
isPnUser,
|
||||
jidDecode,
|
||||
@@ -697,7 +699,7 @@ export const makeMessagesSocket = (config: SocketConfig) => {
|
||||
for (const device of devices) {
|
||||
const deviceJid = device.jid
|
||||
const hasKey = !!senderKeyMap[deviceJid]
|
||||
if (!hasKey || !!participant) {
|
||||
if ((!hasKey || !!participant ) && !isJidHostedLidUser(deviceJid) && !isJidHostedPnUser(deviceJid)) {
|
||||
//todo: revamp all this logic
|
||||
// the goal is to follow with what I said above for each group, and instead of a true false map of ids, we can set an array full of those the app has already sent pkmsgs
|
||||
senderKeyRecipients.push(deviceJid)
|
||||
|
||||
Reference in New Issue
Block a user