mirror of
https://github.com/hoernschen/dendrite.git
synced 2024-12-27 07:28:27 +00:00
Do not add event twice
This commit is contained in:
parent
872d5b93cd
commit
bb163e3d3c
1 changed files with 3 additions and 3 deletions
|
@ -305,15 +305,15 @@ func buildInviteStrippedState(
|
|||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
inputEventUnwrapped := input.Event.Unwrap()
|
||||
inviteState := []gomatrixserverlib.InviteV2StrippedState{
|
||||
gomatrixserverlib.NewInviteV2StrippedState(&input.Event.Event),
|
||||
gomatrixserverlib.NewInviteV2StrippedState(&inputEventUnwrapped),
|
||||
}
|
||||
|
||||
stateEvents = append(stateEvents, types.Event{Event: input.Event.Unwrap()})
|
||||
// stateEvents = append(stateEvents, types.Event{Event: inputEventUnwrapped})
|
||||
for _, event := range stateEvents {
|
||||
inviteState = append(inviteState, gomatrixserverlib.NewInviteV2StrippedState(&event.Event))
|
||||
}
|
||||
fmt.Printf("INVITE STATE: %v\n \n", inviteState)
|
||||
|
||||
return inviteState, nil
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue