mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-03 07:54:48 -04:00
Hook up the push rules to the notifier
This commit is contained in:
parent
2223204eba
commit
ddf9e7b302
5 changed files with 43 additions and 18 deletions
|
@ -115,6 +115,7 @@ class StreamToken(
|
|||
"typing_key",
|
||||
"receipt_key",
|
||||
"account_data_key",
|
||||
"push_rules_key",
|
||||
))
|
||||
):
|
||||
_SEPARATOR = "_"
|
||||
|
@ -150,6 +151,7 @@ class StreamToken(
|
|||
or (int(other.typing_key) < int(self.typing_key))
|
||||
or (int(other.receipt_key) < int(self.receipt_key))
|
||||
or (int(other.account_data_key) < int(self.account_data_key))
|
||||
or (int(other.push_rules_key) < int(self.push_rules_key))
|
||||
)
|
||||
|
||||
def copy_and_advance(self, key, new_value):
|
||||
|
@ -174,6 +176,11 @@ class StreamToken(
|
|||
return StreamToken(**d)
|
||||
|
||||
|
||||
StreamToken.START = StreamToken(
|
||||
*(["s0"] + ["0"] * (len(StreamToken._fields) - 1))
|
||||
)
|
||||
|
||||
|
||||
class RoomStreamToken(namedtuple("_StreamToken", "topological stream")):
|
||||
"""Tokens are positions between events. The token "s1" comes after event 1.
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue