From 91fa5d6a1222377b7d7d6ab73ea5829604d72539 Mon Sep 17 00:00:00 2001 From: Brendan Abolivier Date: Thu, 21 Sep 2017 19:06:57 +0200 Subject: [PATCH] Renamed key for better understandability --- .../matrix-org/dendrite/syncapi/consumers/roomserver.go | 6 +++--- src/github.com/matrix-org/dendrite/syncapi/types/types.go | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/github.com/matrix-org/dendrite/syncapi/consumers/roomserver.go b/src/github.com/matrix-org/dendrite/syncapi/consumers/roomserver.go index ca46828f9..7c40247b0 100644 --- a/src/github.com/matrix-org/dendrite/syncapi/consumers/roomserver.go +++ b/src/github.com/matrix-org/dendrite/syncapi/consumers/roomserver.go @@ -262,9 +262,9 @@ func (s *OutputRoomEvent) updateStateEvent(event gomatrixserverlib.Event) (gomat } prev := types.PrevEventRef{ - PrevContent: prevEvent.Content(), - PrevID: prevEvent.EventID(), - PrevSender: prevEvent.Sender(), + PrevContent: prevEvent.Content(), + ReplacesState: prevEvent.EventID(), + PrevSender: prevEvent.Sender(), } return event.SetUnsigned(prev) diff --git a/src/github.com/matrix-org/dendrite/syncapi/types/types.go b/src/github.com/matrix-org/dendrite/syncapi/types/types.go index cf737a408..f710c6d5d 100644 --- a/src/github.com/matrix-org/dendrite/syncapi/types/types.go +++ b/src/github.com/matrix-org/dendrite/syncapi/types/types.go @@ -31,9 +31,9 @@ func (sp StreamPosition) String() string { // PrevEventRef represents a reference to a previous event in a state event upgrade type PrevEventRef struct { - PrevContent json.RawMessage `json:"prev_content"` - PrevID string `json:"replaces_state"` - PrevSender string `json:"prev_sender"` + PrevContent json.RawMessage `json:"prev_content"` + ReplacesState string `json:"replaces_state"` + PrevSender string `json:"prev_sender"` } // Response represents a /sync API response. See https://matrix.org/docs/spec/client_server/r0.2.0.html#get-matrix-client-r0-sync