Skip to content

Commit ede2869

Browse files
committed
gofmt
Signed-off-by: Alex Ellis (OpenFaaS Ltd) <[email protected]>
1 parent 7a61d11 commit ede2869

File tree

3 files changed

+7
-8
lines changed

3 files changed

+7
-8
lines changed

commands/secret_apply.go

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ import (
1717
)
1818

1919
var secretApplyCmd = &cobra.Command{
20-
Use: `apply [--tls-no-verify]`,
21-
Short: "Apply secrets from .secrets folder",
22-
Long: `Apply all secrets from the .secrets folder to the gateway. Each file in .secrets/ will be synced to the gateway, replacing existing secrets with the same name.`,
20+
Use: `apply [--tls-no-verify]`,
21+
Short: "Apply secrets from .secrets folder",
22+
Long: `Apply all secrets from the .secrets folder to the gateway. Each file in .secrets/ will be synced to the gateway, replacing existing secrets with the same name.`,
2323
Example: ` # Apply all secrets from .secrets folder
2424
faas-cli secret apply
2525
@@ -102,7 +102,7 @@ func runSecretApply(cmd *cobra.Command, args []string) error {
102102
}
103103

104104
secretName := file.Name()
105-
105+
106106
// Validate secret name
107107
isValid, err := validateSecretName(secretName)
108108
if !isValid {
@@ -152,13 +152,13 @@ func runSecretApply(cmd *cobra.Command, args []string) error {
152152
// Create the secret
153153
fmt.Printf("Creating secret: %s.%s\n", secret.Name, functionNamespace)
154154
status, output := client.CreateSecret(context.Background(), secret)
155-
155+
156156
if status == http.StatusConflict {
157157
// If secret still exists (race condition), try update instead
158158
fmt.Printf("Secret %s still exists, updating...\n", secretName)
159159
_, output = client.UpdateSecret(context.Background(), secret)
160160
}
161-
161+
162162
fmt.Print(output)
163163
}
164164

commands/template_pull_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ func Test_templatePull(t *testing.T) {
4444
t.Fatalf("error while listing template directory: %s", err.Error())
4545
}
4646

47-
4847
if err := templatePull(localTemplateRepository, false); err == nil {
4948
t.Fatalf("error expected overwriting existing templates with --overwrite=false:")
5049
}

commands/watch.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ func watchLoop(cmd *cobra.Command, args []string, onChange func(cmd *cobra.Comma
3636
}
3737

3838
fnNames := []string{}
39-
for name, _ := range services.Functions {
39+
for name := range services.Functions {
4040
fnNames = append(fnNames, name)
4141
}
4242

0 commit comments

Comments
 (0)