From 1940007ca5d995a5e3887c5b8acfe06cdce559ea Mon Sep 17 00:00:00 2001 From: Michael Palmer Date: Tue, 27 Oct 2020 09:24:37 -0400 Subject: [PATCH] check for errors from ping --- pkg/provider/pingfed/pingfed.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pkg/provider/pingfed/pingfed.go b/pkg/provider/pingfed/pingfed.go index d1b1fdd12..70882978d 100644 --- a/pkg/provider/pingfed/pingfed.go +++ b/pkg/provider/pingfed/pingfed.go @@ -218,8 +218,7 @@ func (ac *Client) handleLogin(ctx context.Context, doc *goquery.Document) (conte // Check for errors from Ping pingErrors := doc.Find("form>.ping-messages>.ping-error") if pingErrors.Size() == 1 { - errorContent := pingErrors.Text() - return ctx, nil, errors.New(errorContent) + return ctx, nil, errors.New(pingErrors.Text()) } if loginAttempt > 1 {