mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-05 13:44:56 -04:00
Add StreamKeyType
class and replace string literals with constants (#12567)
This commit is contained in:
parent
3ce15cc7be
commit
83be72d76c
19 changed files with 125 additions and 80 deletions
|
@ -73,6 +73,7 @@ from synapse.types import (
|
|||
RoomID,
|
||||
RoomStreamToken,
|
||||
StateMap,
|
||||
StreamKeyType,
|
||||
StreamToken,
|
||||
UserID,
|
||||
create_requester,
|
||||
|
@ -1292,10 +1293,10 @@ class RoomContextHandler:
|
|||
events_after=events_after,
|
||||
state=await filter_evts(state_events),
|
||||
aggregations=aggregations,
|
||||
start=await token.copy_and_replace("room_key", results.start).to_string(
|
||||
self.store
|
||||
),
|
||||
end=await token.copy_and_replace("room_key", results.end).to_string(
|
||||
start=await token.copy_and_replace(
|
||||
StreamKeyType.ROOM, results.start
|
||||
).to_string(self.store),
|
||||
end=await token.copy_and_replace(StreamKeyType.ROOM, results.end).to_string(
|
||||
self.store
|
||||
),
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue