matrix: Don't send out read markers with an empty event id.
This commit is contained in:
parent
e39b6a82b1
commit
9644ae5b65
1 changed files with 7 additions and 3 deletions
4
main.py
4
main.py
|
@ -490,6 +490,10 @@ def buffer_switch_cb(_, _signal, buffer_ptr):
|
||||||
|
|
||||||
if room_buffer.should_send_read_marker:
|
if room_buffer.should_send_read_marker:
|
||||||
event_id = room_buffer.last_event_id
|
event_id = room_buffer.last_event_id
|
||||||
|
|
||||||
|
# A buffer may not have any events, in that case no event id is
|
||||||
|
# here returned
|
||||||
|
if event_id:
|
||||||
server.room_send_read_marker(
|
server.room_send_read_marker(
|
||||||
room_buffer.room.room_id, event_id)
|
room_buffer.room.room_id, event_id)
|
||||||
room_buffer.last_read_event = event_id
|
room_buffer.last_read_event = event_id
|
||||||
|
|
Loading…
Add table
Reference in a new issue