mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-10 16:33:11 -06:00
Improve iteration
This commit is contained in:
parent
f8cb14678c
commit
e73e5413f1
|
|
@ -302,9 +302,7 @@ func buildMembershipEvents(
|
|||
|
||||
authEvents := gomatrixserverlib.NewAuthEvents(nil)
|
||||
|
||||
// Iterating the old way because range seems to mess things up. Might be
|
||||
// worth investigating.
|
||||
for i := 0; i < len(queryRes.StateEvents); i++ {
|
||||
for i := range queryRes.StateEvents {
|
||||
authEvents.AddEvent(&queryRes.StateEvents[i])
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue