diff --git a/common/util.go b/common/util.go index 2cd652a4..48c4be8f 100644 --- a/common/util.go +++ b/common/util.go @@ -92,12 +92,12 @@ func HandleHTTPRequest(message string, headers http.Header, data ConnectorMetada } if resp.StatusCode < 200 || resp.StatusCode > 300 { - return nil, fmt.Errorf("request returned failure: %v. http_endpoint: %v, source: %v", resp.StatusCode, data.HTTPEndpoint, data.SourceName) + return resp, fmt.Errorf("request returned failure: %v. http_endpoint: %v, source: %v", resp.StatusCode, data.HTTPEndpoint, data.SourceName) } return resp, nil } -//GetAwsConfig get's the configuration required to connect to aws +// GetAwsConfig get's the configuration required to connect to aws func GetAwsConfig() (*aws.Config, error) { if os.Getenv("AWS_REGION") == "" { return nil, errors.New("aws region required")