diff --git a/builtin/providers/cloudflare/resource_cloudflare_record.go b/builtin/providers/cloudflare/resource_cloudflare_record.go index b0bdf65a53..b0000fe4aa 100644 --- a/builtin/providers/cloudflare/resource_cloudflare_record.go +++ b/builtin/providers/cloudflare/resource_cloudflare_record.go @@ -95,7 +95,7 @@ func resourceCloudFlareRecordCreate(d *schema.ResourceData, meta interface{}) er // Validate type if err := validateRecordType(newRecord.Type, newRecord.Proxied); err != nil { - fmt.Errorf("Error validating record type %q: %s", newRecord.Type, err) + return fmt.Errorf("Error validating record type %q: %s", newRecord.Type, err) } zoneId, err := client.ZoneIDByName(newRecord.ZoneName)