Skip to content

Commit df9ffdc

Browse files
authored
Don't ignore call member events with a distant future expiration date (#2466)
to match updates to MSC3401
1 parent 70449ea commit df9ffdc

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/webrtc/groupCall.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -139,8 +139,7 @@ const callMemberStateIsExpired = (event: MatrixEvent): boolean => {
139139
const now = Date.now();
140140
const content = event?.getContent<IGroupCallRoomMemberState>() ?? {};
141141
const expiresAt = typeof content["m.expires_ts"] === "number" ? content["m.expires_ts"] : -Infinity;
142-
// The event is expired if the expiration date has passed, or if it's unreasonably far in the future
143-
return expiresAt <= now || expiresAt > now + CALL_MEMBER_STATE_TIMEOUT * 5 / 4;
142+
return expiresAt <= now;
144143
};
145144

146145
function getCallUserId(call: MatrixCall): string | null {

0 commit comments

Comments
 (0)