Fix state key invite membership events not being correctly set

This commit is contained in:
Brendan Abolivier 2017-08-02 14:08:13 +01:00
parent 85268ff02a
commit 1be6290e62
No known key found for this signature in database
GPG key ID: 8EF1500759F70623

View file

@ -106,7 +106,7 @@ func SendMembership(
func getMembershipStateKey(
req *http.Request, device *authtypes.Device, membership string,
) (stateKey string, reason string, response *util.JSONResponse) {
if membership == "ban" || membership == "unban" || membership == "kick" {
if membership == "ban" || membership == "unban" || membership == "kick" || membership == "invite" {
// If we're in this case, the state key is contained in the request body,
// possibly along with a reason (for "kick" and "ban") so we need to parse
// it