From 1076719c0834c493473096960b208ea1d2e089f7 Mon Sep 17 00:00:00 2001 From: Brendan Abolivier Date: Tue, 29 Aug 2017 15:13:48 +0100 Subject: [PATCH] Don't copy the public keys array --- .../dendrite/clientapi/thirdpartyinvites/thirdpartyinvites.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/github.com/matrix-org/dendrite/clientapi/thirdpartyinvites/thirdpartyinvites.go b/src/github.com/matrix-org/dendrite/clientapi/thirdpartyinvites/thirdpartyinvites.go index def913700..c998a6522 100644 --- a/src/github.com/matrix-org/dendrite/clientapi/thirdpartyinvites/thirdpartyinvites.go +++ b/src/github.com/matrix-org/dendrite/clientapi/thirdpartyinvites/thirdpartyinvites.go @@ -335,11 +335,9 @@ func emit3PIDInviteEvent( DisplayName: res.DisplayName, KeyValidityURL: validityURL, PublicKey: res.PublicKey, + PublicKeys: res.PublicKeys, } - content.PublicKeys = make([]common.PublicKey, len(res.PublicKeys)) - copy(content.PublicKeys, res.PublicKeys) - if err := builder.SetContent(content); err != nil { return err }