From f312b2af00662ae925ace0417fdc0d4d4bd9c3d4 Mon Sep 17 00:00:00 2001 From: Andrew Starr-Bochicchio Date: Wed, 17 Jul 2024 11:46:21 -0400 Subject: [PATCH] misc: clean up additional typos found in CI. --- commands/functions.go | 14 +++++++------- commands/volume_actions.go | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/commands/functions.go b/commands/functions.go index 9d0d88075..409235caf 100644 --- a/commands/functions.go +++ b/commands/functions.go @@ -92,7 +92,7 @@ func RunFunctionsGet(c *CmdConfig) error { fetchCode := codeFlag || saveFlag || saveAsFlag != "" sls := c.Serverless() - action, parms, err := sls.GetFunction(c.Args[0], fetchCode) + action, params, err := sls.GetFunction(c.Args[0], fetchCode) if err != nil { return err } @@ -111,7 +111,7 @@ func RunFunctionsGet(c *CmdConfig) error { } if saveEnvFlag != "" || saveEnvJSONFlag != "" { - return doSaveFunctionEnvironment(saveEnvFlag, saveEnvJSONFlag, parms) + return doSaveFunctionEnvironment(saveEnvFlag, saveEnvJSONFlag, params) } if codeFlag { @@ -156,14 +156,14 @@ func doSaveFunctionCode(action whisk.Action, save bool, saveAs string) error { // doSaveFunctionEnvironment saves the environment variables for a function to file, // either as key-value pairs or JSON. Could do both if both are specified. -func doSaveFunctionEnvironment(saveEnv string, saveEnvJSON string, parms []do.FunctionParameter) error { +func doSaveFunctionEnvironment(saveEnv string, saveEnvJSON string, params []do.FunctionParameter) error { keyVals := []string{} envMap := map[string]string{} - for _, parm := range parms { - if parm.Init { - keyVal := parm.Key + "=" + parm.Value + for _, p := range params { + if p.Init { + keyVal := p.Key + "=" + p.Value keyVals = append(keyVals, keyVal) - envMap[parm.Key] = parm.Value + envMap[p.Key] = p.Value } } diff --git a/commands/volume_actions.go b/commands/volume_actions.go index 656e83d92..94fcf68ed 100644 --- a/commands/volume_actions.go +++ b/commands/volume_actions.go @@ -78,7 +78,7 @@ func VolumeAction() *Command { cmdVolumeActionsList := CmdBuilder(cmd, RunVolumeActionsList, "list ", "Retrieve a list of actions taken on a volume", `Retrieves a list of actions taken on a volume. The following details are provided:`+actionDetail, Writer, aliasOpt("ls"), displayerType(&displayers.Action{})) - cmdVolumeActionsList.Example = `The following example retrieves a list of actions taken on a volume with the UUID ` + "`" + `f81d4fae-7dec-11d0-a765-00a0c91e6bf6` + "`" + `. The command also uses the ` + "`" + `--format` + "`" + ` flag to return ony the resource ID and status for each action listed: doctl compute volume-action list f81d4fae-7dec-11d0-a765-00a0c91e6bf6 --format ResourceID,Status` + cmdVolumeActionsList.Example = `The following example retrieves a list of actions taken on a volume with the UUID ` + "`" + `f81d4fae-7dec-11d0-a765-00a0c91e6bf6` + "`" + `. The command also uses the ` + "`" + `--format` + "`" + ` flag to return only the resource ID and status for each action listed: doctl compute volume-action list f81d4fae-7dec-11d0-a765-00a0c91e6bf6 --format ResourceID,Status` cmdRunVolumeAttach := CmdBuilder(cmd, RunVolumeAttach, "attach ", "Attach a volume to a Droplet", `Attaches a block storage volume to a Droplet.