From c3b8cbd608f178b704aa92efdfd75036dfe02d48 Mon Sep 17 00:00:00 2001 From: Tim Ramlot <42113979+inteon@users.noreply.github.com> Date: Thu, 8 Feb 2024 17:20:36 +0100 Subject: [PATCH] improve comment that explains what removeReqID does and when it fails Signed-off-by: Tim Ramlot <42113979+inteon@users.noreply.github.com> --- pkg/issuer/acme/dns/route53/route53.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkg/issuer/acme/dns/route53/route53.go b/pkg/issuer/acme/dns/route53/route53.go index 36c9a2c03..8213077ea 100644 --- a/pkg/issuer/acme/dns/route53/route53.go +++ b/pkg/issuer/acme/dns/route53/route53.go @@ -292,7 +292,10 @@ func newTXTRecordSet(fqdn, value string, ttl int) *route53types.ResourceRecordSe // avoid spurious challenge updates. // // The given error must not be nil. This function must be called everywhere -// we have a non-nil error coming from an aws-sdk-go func. +// we have a non-nil error coming from an aws-sdk-go func. The passed error +// is modified in place. This function does not work in case the full error +// message is pre-generated at construction time (instead of when Error() is +// called), which is the case for eg. fmt.Errorf("error message: %w", err). func removeReqID(err error) error { var responseError *awshttp.ResponseError if errors.As(err, &responseError) {