mirror of
https://github.com/matrix-org/dendrite.git
synced 2026-01-16 10:33:11 -06:00
Check the correct error code in PerformJoin
This commit is contained in:
parent
83daf12fe5
commit
c0a4599b2f
|
|
@ -163,13 +163,13 @@ func (r *FederationInternalAPI) performJoinUsingServer(
|
|||
}
|
||||
response, joinErr := gomatrixserverlib.PerformJoin(ctx, r, joinInput)
|
||||
|
||||
if err != nil {
|
||||
if joinErr != nil {
|
||||
if !joinErr.Reachable {
|
||||
r.statistics.ForServer(joinErr.ServerName).Failure()
|
||||
} else {
|
||||
r.statistics.ForServer(joinErr.ServerName).Success(statistics.SendDirect)
|
||||
}
|
||||
return err
|
||||
return joinErr
|
||||
}
|
||||
r.statistics.ForServer(serverName).Success(statistics.SendDirect)
|
||||
if response == nil {
|
||||
|
|
|
|||
Loading…
Reference in a new issue