fix: properly fetch keys for config command

This commit is contained in:
Jose Diaz-Gonzalez
2020-05-29 14:50:17 -04:00
parent aff0c1fc40
commit 88f661b6e7
2 changed files with 2 additions and 1 deletions

View File

@@ -12,7 +12,7 @@ import (
func getKeys(args []string, global bool) []string {
keys := args
if !global && len(keys) > 1 {
if !global && len(keys) > 0 {
keys = keys[1:]
}
return keys

View File

@@ -120,6 +120,7 @@ func CommandSet(appName string, pairs []string, global bool, noRestart bool, enc
if len(pairs) == 0 {
return errors.New("At least one env pair must be given")
}
updated := make(map[string]string)
for _, e := range pairs {
parts := strings.SplitN(e, "=", 2)