mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2025-01-11 04:27:40 +01:00
don't set dmUserId when not a DM
This commit is contained in:
parent
7defd4a02b
commit
45837f7377
@ -183,10 +183,11 @@ function applyInvite(data, invite) {
|
|||||||
if (data.isDirectMessage !== invite.isDirectMessage) {
|
if (data.isDirectMessage !== invite.isDirectMessage) {
|
||||||
data = data.cloneIfNeeded();
|
data = data.cloneIfNeeded();
|
||||||
data.isDirectMessage = invite.isDirectMessage;
|
data.isDirectMessage = invite.isDirectMessage;
|
||||||
}
|
if (invite.isDirectMessage) {
|
||||||
if (data.dmUserId !== invite.inviter?.userId) {
|
|
||||||
data = data.cloneIfNeeded();
|
|
||||||
data.dmUserId = invite.inviter?.userId;
|
data.dmUserId = invite.inviter?.userId;
|
||||||
|
} else {
|
||||||
|
data.dmUserId = null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return data;
|
return data;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user