provider/heroku: scope valid stage names to func

This commit is contained in:
Justin Campbell 2017-05-01 10:20:51 -04:00
parent 02bb1e6907
commit 61f45dd585
1 changed files with 7 additions and 7 deletions

View File

@ -7,14 +7,14 @@ import (
"github.com/satori/uuid"
)
var validPipelineStageNames = []string{
"review",
"development",
"staging",
"production",
}
func validatePipelineStageName(v interface{}, k string) (ws []string, errors []error) {
validPipelineStageNames := []string{
"review",
"development",
"staging",
"production",
}
for _, s := range validPipelineStageNames {
if v == s {
return