Skip to content

Commit

Permalink
Fix #10 by sorting strings slices
Browse files Browse the repository at this point in the history
  • Loading branch information
Nosmoht committed Apr 16, 2020
1 parent 96e0dfe commit 34d97fc
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions nexus/tools.go
Expand Up @@ -3,6 +3,7 @@ package nexus
import (
"fmt"
"os"
"sort"

"github.com/hashicorp/terraform-plugin-sdk/helper/schema"
)
Expand All @@ -13,6 +14,7 @@ func resourceDataStringSlice(d *schema.ResourceData, attribute string) []string
for i := 0; i < n; i++ {
data[i] = d.Get(fmt.Sprintf("%s.%d", attribute, i)).(string)
}
sort.Strings(data)
return data
}

Expand Down

0 comments on commit 34d97fc

Please sign in to comment.