Przeglądaj źródła

Merge pull request #24 from kubecost/AjayTripathy-fix-build

migrate from errors.new -> fmt.Errorf
Ajay Tripathy 7 lat temu
rodzic
commit
0648890523
1 zmienionych plików z 1 dodań i 2 usunięć
  1. 1 2
      cloud/awsprovider.go

+ 1 - 2
cloud/awsprovider.go

@@ -293,8 +293,7 @@ func (aws *AWS) NodePricing(key string) (*Node, error) {
 		}
 		terms, termsOk := aws.Pricing[key]
 		if !termsOk {
-			log.Printf("Unable to find any Pricing data for \"%s\"", key)
-			return nil, errors.New("Missing aws.Pricing")
+			return nil, fmt.Errorf("Unable to find any Pricing data for \"%s\"", key)
 		}
 		if aws.isPreemptible(key) {
 			return &Node{