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 May 15, 2020
1 parent dcdbe25 commit 3fd81a6
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
3 changes: 2 additions & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ linters-settings:
# also, for anyone using vscode, use the following configs:
# "rewrap.wrappingColumn": 140 ... requires the rewrap plugin
# "editor.rulers": [140]
line-length: 140
line-length: 150

linters:
enable-all: true
Expand All @@ -48,6 +48,7 @@ linters:
- wsl
- nestif
- godot
- goconst

issues:
exclude:
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 3fd81a6

Please sign in to comment.