mirror of
https://github.com/fnproject/fn.git
synced 2022-10-28 21:29:17 +03:00
fn: apps commands improvements (#476)
* improve apps commands * fix app and routes update config and headers unset * add the command config set/unset back * prevent extractEnvConfig to panic if not valid key=value * add examples to readme.md * fix fn routes
This commit is contained in:
committed by
Travis Reeder
parent
5609a76c19
commit
c62e22f5fe
@@ -185,7 +185,9 @@ func extractEnvConfig(configs []string) map[string]string {
|
||||
c := make(map[string]string)
|
||||
for _, v := range configs {
|
||||
kv := strings.SplitN(v, "=", 2)
|
||||
c[kv[0]] = os.ExpandEnv(kv[1])
|
||||
if len(kv) == 2 {
|
||||
c[kv[0]] = os.ExpandEnv(kv[1])
|
||||
}
|
||||
}
|
||||
return c
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user