mirror of
https://github.com/hoernschen/dendrite.git
synced 2025-07-29 12:42:46 +00:00
Clean up a bit
This commit is contained in:
parent
6016d378a0
commit
e874853ed0
4 changed files with 5 additions and 12 deletions
|
@ -5,7 +5,6 @@ import (
|
|||
"encoding/json"
|
||||
"errors"
|
||||
"fmt"
|
||||
"net/http"
|
||||
"time"
|
||||
|
||||
"github.com/matrix-org/dendrite/federationsender/api"
|
||||
|
@ -116,12 +115,6 @@ func (r *FederationSenderInternalAPI) PerformJoin(
|
|||
// Clear the wrapped error, else serialising to JSON (in polylith mode) will fail
|
||||
httpErr.WrappedError = nil
|
||||
response.LastError = &httpErr
|
||||
} else if errors.Is(lastErr, &gomatrixserverlib.NotAllowed{}) {
|
||||
response.LastError = &gomatrix.HTTPError{
|
||||
Code: http.StatusForbidden,
|
||||
WrappedError: lastErr,
|
||||
Message: lastErr.Error(),
|
||||
}
|
||||
} else {
|
||||
response.LastError = &gomatrix.HTTPError{
|
||||
Code: 0,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue