aboutsummaryrefslogtreecommitdiff
path: root/vendor/github.com/spf13/pflag/string_array.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/spf13/pflag/string_array.go')
-rw-r--r--vendor/github.com/spf13/pflag/string_array.go3
1 files changed, 1 insertions, 2 deletions
diff --git a/vendor/github.com/spf13/pflag/string_array.go b/vendor/github.com/spf13/pflag/string_array.go
index f320f2e..93b4e43 100644
--- a/vendor/github.com/spf13/pflag/string_array.go
+++ b/vendor/github.com/spf13/pflag/string_array.go
@@ -2,7 +2,6 @@ package pflag
import (
"fmt"
- "strings"
)
var _ = fmt.Fprint
@@ -40,7 +39,7 @@ func (s *stringArrayValue) String() string {
}
func stringArrayConv(sval string) (interface{}, error) {
- sval = strings.Trim(sval, "[]")
+ sval = sval[1 : len(sval)-1]
// An empty string would cause a array with one (empty) string
if len(sval) == 0 {
return []string{}, nil