diff options
author | Patrick Cloke <patrickc@matrix.org> | 2023-04-07 10:17:21 -0400 |
---|---|---|
committer | Patrick Cloke <patrickc@matrix.org> | 2023-07-17 11:05:43 -0400 |
commit | c02f1153069d6abae931e46d2351c53ecc8b185a (patch) | |
tree | 2ded549b33dd30e9cb50ae5c63e68f690efa581d /synapse/handlers/federation.py | |
parent | Remove references to m.room.hub events. (diff) | |
download | synapse-c02f1153069d6abae931e46d2351c53ecc8b185a.tar.xz |
Linearized Matrix events do not have a depth.
Diffstat (limited to '')
-rw-r--r-- | synapse/handlers/federation.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/synapse/handlers/federation.py b/synapse/handlers/federation.py index cc5ed97730..d90a14788d 100644 --- a/synapse/handlers/federation.py +++ b/synapse/handlers/federation.py @@ -662,7 +662,9 @@ class FederationHandler: origin = ret.origin state = ret.state auth_chain = ret.auth_chain - auth_chain.sort(key=lambda e: e.depth) + # TODO(LM) Assume the auth chain is reasonable ordered. + if not room_version_obj.linearized_matrix: + auth_chain.sort(key=lambda e: e.depth) logger.debug("do_invite_join auth_chain: %s", auth_chain) logger.debug("do_invite_join state: %s", state) |