@@ -11,7 +11,6 @@ import (
1111 "github.com/aws/aws-sdk-go/aws/awserr"
1212 "github.com/aws/aws-sdk-go/service/elasticache"
1313 "github.com/aws/aws-sdk-go/service/iam"
14- "github.com/hashicorp/terraform/helper/hashcode"
1514 "github.com/hashicorp/terraform/helper/resource"
1615 "github.com/hashicorp/terraform/helper/schema"
1716)
@@ -89,18 +88,14 @@ func resourceAwsElasticacheCluster() *schema.Resource {
8988 Computed : true ,
9089 ForceNew : true ,
9190 Elem : & schema.Schema {Type : schema .TypeString },
92- Set : func (v interface {}) int {
93- return hashcode .String (v .(string ))
94- },
91+ Set : schema .HashString ,
9592 },
9693 "security_group_ids" : & schema.Schema {
9794 Type : schema .TypeSet ,
9895 Optional : true ,
9996 Computed : true ,
10097 Elem : & schema.Schema {Type : schema .TypeString },
101- Set : func (v interface {}) int {
102- return hashcode .String (v .(string ))
103- },
98+ Set : schema .HashString ,
10499 },
105100 // Exported Attributes
106101 "cache_nodes" : & schema.Schema {
@@ -142,9 +137,7 @@ func resourceAwsElasticacheCluster() *schema.Resource {
142137 Optional : true ,
143138 ForceNew : true ,
144139 Elem : & schema.Schema {Type : schema .TypeString },
145- Set : func (v interface {}) int {
146- return hashcode .String (v .(string ))
147- },
140+ Set : schema .HashString ,
148141 },
149142
150143 "snapshot_window" : & schema.Schema {
@@ -185,9 +178,7 @@ func resourceAwsElasticacheCluster() *schema.Resource {
185178 Optional : true ,
186179 ForceNew : true ,
187180 Elem : & schema.Schema {Type : schema .TypeString },
188- Set : func (v interface {}) int {
189- return hashcode .String (v .(string ))
190- },
181+ Set : schema .HashString ,
191182 },
192183
193184 "tags" : tagsSchema (),
0 commit comments