mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-20 21:33:19 -06:00
Unbreak everything; thanks Go!
This commit is contained in:
parent
bb73c33d02
commit
da441b60fc
|
|
@ -108,5 +108,10 @@ func SendInvite(
|
||||||
}
|
}
|
||||||
var response PerformInviteResponse
|
var response PerformInviteResponse
|
||||||
rsAPI.PerformInvite(ctx, &request, &response)
|
rsAPI.PerformInvite(ctx, &request, &response)
|
||||||
|
// we need to do this because many places people will use `var err error` as the return
|
||||||
|
// arg and a nil interface != nil pointer to a concrete interface (in this case PerformError)
|
||||||
|
if response.Error != nil && response.Error.Msg != "" {
|
||||||
return response.Error
|
return response.Error
|
||||||
}
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue