Explorar el Código

make sure default pricing errors are handled

AjayTripathy hace 6 años
padre
commit
4f82cfdeba
Se han modificado 1 ficheros con 3 adiciones y 3 borrados
  1. 3 3
      cloud/gcpprovider.go

+ 3 - 3
cloud/gcpprovider.go

@@ -86,12 +86,12 @@ func (gcp *GCP) GetLocalStorageQuery() (string, error) {
 
 func (gcp *GCP) GetConfig() (*CustomPricing, error) {
 	c, err := GetDefaultPricingData("gcp.json")
-	if c.Discount == "" {
-		c.Discount = "30%"
-	}
 	if err != nil {
 		return nil, err
 	}
+	if c.Discount == "" {
+		c.Discount = "30%"
+	}
 	return c, nil
 }