Merge pull request #3284 from stack72/do_size_slug

provider/digitalocean - Droplet Size Lowercase
This commit is contained in:
Paul Hinze 2015-10-12 07:06:53 -05:00
commit 22681c3db2
1 changed files with 4 additions and 0 deletions

View File

@ -39,6 +39,10 @@ func resourceDigitalOceanDroplet() *schema.Resource {
"size": &schema.Schema{ "size": &schema.Schema{
Type: schema.TypeString, Type: schema.TypeString,
Required: true, Required: true,
StateFunc: func(val interface{}) string {
// DO API V2 size slug is always lowercase
return strings.ToLower(val.(string))
},
}, },
"status": &schema.Schema{ "status": &schema.Schema{