Skip to content

Commit

Permalink
refactor: changed to make it work for lint
Browse files Browse the repository at this point in the history
  • Loading branch information
Edgar López committed Nov 24, 2020
1 parent 534ca05 commit 8e9c23f
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
6 changes: 3 additions & 3 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ linters-settings:
# Default is 120. '\t' is counted as 1 character.
# set our project to 200, as things like v3_structs with inline comments end up being a touch long
# also, for anyone using vscode, use the following configs:
# "rewrap.wrappingColumn": 200 ... requires the rewrap plugin
# "editor.rulers": [200]
line-length: 200
# "rewrap.wrappingColumn": 140 ... requires the rewrap plugin
# "editor.rulers": [140]
line-length: 150

linters:
enable-all: true
Expand Down
6 changes: 4 additions & 2 deletions nutanix/data_source_protection_rule.go
Original file line number Diff line number Diff line change
Expand Up @@ -276,10 +276,12 @@ func dataSourceNutanixProtectionRuleRead(d *schema.ResourceData, meta interface{
if err := d.Set("category_filter", flattenCategoriesFilter(resp.Spec.Resources.CategoryFilter)); err != nil {
return err
}
if err := d.Set("availability_zone_connectivity_list", flattenAvailabilityZoneConnectivityList(resp.Spec.Resources.AvailabilityZoneConnectivityList)); err != nil {
if err := d.Set("availability_zone_connectivity_list",
flattenAvailabilityZoneConnectivityList(resp.Spec.Resources.AvailabilityZoneConnectivityList)); err != nil {
return err
}
if err := d.Set("ordered_availability_zone_list", flattenOrderAvailibilityList(resp.Spec.Resources.OrderedAvailabilityZoneList)); err != nil {
if err := d.Set("ordered_availability_zone_list",
flattenOrderAvailibilityList(resp.Spec.Resources.OrderedAvailabilityZoneList)); err != nil {
return err
}
if err := d.Set("state", resp.Status.State); err != nil {
Expand Down
6 changes: 4 additions & 2 deletions nutanix/resource_nutanix_protection_rule.go
Original file line number Diff line number Diff line change
Expand Up @@ -392,10 +392,12 @@ func resourceNutanixProtectionRuleRead(d *schema.ResourceData, meta interface{})
if err := d.Set("category_filter", flattenCategoriesFilter(resp.Spec.Resources.CategoryFilter)); err != nil {
return err
}
if err := d.Set("availability_zone_connectivity_list", flattenAvailabilityZoneConnectivityList(resp.Spec.Resources.AvailabilityZoneConnectivityList)); err != nil {
if err := d.Set("availability_zone_connectivity_list",
flattenAvailabilityZoneConnectivityList(resp.Spec.Resources.AvailabilityZoneConnectivityList)); err != nil {
return err
}
if err := d.Set("ordered_availability_zone_list", flattenOrderAvailibilityList(resp.Spec.Resources.OrderedAvailabilityZoneList)); err != nil {
if err := d.Set("ordered_availability_zone_list",
flattenOrderAvailibilityList(resp.Spec.Resources.OrderedAvailabilityZoneList)); err != nil {
return err
}
if err := d.Set("state", resp.Status.State); err != nil {
Expand Down

0 comments on commit 8e9c23f

Please sign in to comment.