Skip to content

Commit

Permalink
fix up validation
Browse files Browse the repository at this point in the history
  • Loading branch information
stuartleeks committed Jul 10, 2019
1 parent c4a6671 commit df7cbec
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions azurerm/resource_arm_storage_management_policy.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ func resourceArmStorageManagementPolicy() *schema.Resource {
"name": {
Type: schema.TypeString,
Required: true,
validation.StringMatch(
ValidateFunc: validation.StringMatch(
regexp.MustCompile(`^[a-zA-Z0-9]*$`),
"A rule name can contain any combination of alpha numeric characters.",
),
Expand All @@ -63,11 +63,13 @@ func resourceArmStorageManagementPolicy() *schema.Resource {
Set: schema.HashString,
},
"blob_types": {
Type: schema.TypeSet,
Optional: true,
Elem: &schema.Schema{Type: schema.TypeString},
Set: schema.HashString,
ValidateFunc: validation.StringInSlice([]string{"blockBlob"}, false),
Type: schema.TypeSet,
Optional: true,
Elem: &schema.Schema{
Type: schema.TypeString,
ValidateFunc: validation.StringInSlice([]string{"blockBlob"}, false),
},
Set: schema.HashString,
},
},
},
Expand Down

0 comments on commit df7cbec

Please sign in to comment.