2
0

rename error

This commit is contained in:
sergey.bashilov
2022-06-24 14:20:36 +03:00
committed by Jack Christensen
parent 618a12a094
commit cdc240d920
3 changed files with 6 additions and 6 deletions
+4 -4
View File
@@ -220,19 +220,19 @@ func redactURL(u *url.URL) string {
return u.String()
}
type NotStandbyError struct {
type NotPreferredError struct {
err error
safeToRetry bool
}
func (e *NotStandbyError) Error() string {
func (e *NotPreferredError) Error() string {
return fmt.Sprintf("standby server not found: %s", e.err.Error())
}
func (e *NotStandbyError) SafeToRetry() bool {
func (e *NotPreferredError) SafeToRetry() bool {
return e.safeToRetry
}
func (e *NotStandbyError) Unwrap() error {
func (e *NotPreferredError) Unwrap() error {
return e.err
}