mirror of
https://mau.dev/maunium/synapse.git
synced 2024-12-18 00:43:51 +01:00
Handle empty events table
This commit is contained in:
parent
d4503e25ed
commit
18d68bfee4
1 changed files with 3 additions and 0 deletions
|
@ -293,6 +293,9 @@ class EventPushActionsStore(SQLBaseStore):
|
||||||
txn.execute("SELECT MAX(stream_ordering) FROM events")
|
txn.execute("SELECT MAX(stream_ordering) FROM events")
|
||||||
max_stream_ordering = txn.fetchone()[0]
|
max_stream_ordering = txn.fetchone()[0]
|
||||||
|
|
||||||
|
if max_stream_ordering is None:
|
||||||
|
return 0
|
||||||
|
|
||||||
range_start = 0
|
range_start = 0
|
||||||
range_end = max_stream_ordering
|
range_end = max_stream_ordering
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue