From db18a0c49dc1174479eb1d903d80357315a49856 Mon Sep 17 00:00:00 2001 From: David Robertson Date: Mon, 13 Jun 2022 17:07:56 +0100 Subject: [PATCH] Conflicted state set is a set of events In #1042 I incorrectly wrote that the conflicted state set is a set of pairs (K, V). We later take the union of the conflicted state set and the auth difference. The latter is a set of events (V) only. Fix this by making the conflicted state set a set of events rather than a set of pairs. That is, the conflicted state set is a a `Set[Event]` instead of a `Set[((type, state key), event)]`. --- content/rooms/fragments/v2-state-res.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/content/rooms/fragments/v2-state-res.md b/content/rooms/fragments/v2-state-res.md index e666d7f8..51331b44 100644 --- a/content/rooms/fragments/v2-state-res.md +++ b/content/rooms/fragments/v2-state-res.md @@ -36,10 +36,10 @@ The key-value pairs (*K*, *V*) across all state maps *Si* can be divided into two collections. If a given key *K* is present in every *Si* with the same value *V* in each state map, then the pair (*K*, *V*) belongs to the *unconflicted state map*. -Otherwise (*K*, *V*) belongs to the *conflicted state set*. +Otherwise, *V* belongs to the *conflicted state set*. Note that the unconflicted state map only has one event for each key *K*, -whereas the conflicted state set may associate multiple events to the same key. +whereas the conflicted state set may contain multiple events with the same key. **Auth chain.** The *auth chain* of an event *E* is the set containing all of *E*'s auth events,