From 894e7800149feb7c184c90ed117ad0f61838833d Mon Sep 17 00:00:00 2001 From: Fabian Hoffmann <35104465+FabHof@users.noreply.github.com> Date: Mon, 7 Mar 2022 09:46:25 +0100 Subject: [PATCH] Improve ErrUnexpectedStatus default string Signed-off-by: Fabian Hoffmann --- remotes/errors/errors.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/remotes/errors/errors.go b/remotes/errors/errors.go index 67ccb23df..f60ff0fc2 100644 --- a/remotes/errors/errors.go +++ b/remotes/errors/errors.go @@ -33,7 +33,7 @@ type ErrUnexpectedStatus struct { } func (e ErrUnexpectedStatus) Error() string { - return fmt.Sprintf("unexpected status: %s", e.Status) + return fmt.Sprintf("unexpected status from %s request to %s: %s", e.RequestMethod, e.RequestURL, e.Status) } // NewUnexpectedStatusErr creates an ErrUnexpectedStatus from HTTP response