mirror of
https://github.com/matrix-org/dendrite.git
synced 2025-12-12 09:23:09 -06:00
Add new error
This commit is contained in:
parent
9f3078e32b
commit
858442d8cc
|
|
@ -104,3 +104,12 @@ func LimitExceeded(msg string, retryAfterMS int64) *LimitExceededError {
|
||||||
RetryAfterMS: retryAfterMS,
|
RetryAfterMS: retryAfterMS,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// NotTrusted is an error which is returned when the client asks the server to
|
||||||
|
// proxy a request (e.g. 3PID association) to a server that isn't trusted
|
||||||
|
func NotTrusted(serverName string) *MatrixError {
|
||||||
|
return &MatrixError{
|
||||||
|
ErrCode: "M_SERVER_NOT_TRUSTED",
|
||||||
|
Err: fmt.Sprintf("Untrusted server '%s'", serverName),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue