Procházet zdrojové kódy

remove unused field

Feroze Mohideen před 2 roky
rodič
revize
b6929665c6
2 změnil soubory, kde provedl 12 přidání a 17 odebrání
  1. 6 7
      cli/cmd/commands/app.go
  2. 6 10
      cli/cmd/v2/update_image.go

+ 6 - 7
cli/cmd/commands/app.go

@@ -1259,13 +1259,12 @@ func appUpdateTag(ctx context.Context, user *types.GetAuthenticatedUserResponse,
 
 	if project.ValidateApplyV2 {
 		revisionId, err := v2.UpdateImage(ctx, v2.UpdateImageInput{
-			ProjectID:               cliConf.Project,
-			ClusterID:               cliConf.Cluster,
-			AppName:                 args[0],
-			DeploymentTargetName:    deploymentTarget,
-			Tag:                     appTag,
-			WaitForSuccessfulUpdate: waitForSuccessfulUpdate,
-			Client:                  client,
+			ProjectID:            cliConf.Project,
+			ClusterID:            cliConf.Cluster,
+			AppName:              args[0],
+			DeploymentTargetName: deploymentTarget,
+			Tag:                  appTag,
+			Client:               client,
 		})
 		if err != nil {
 			return fmt.Errorf("error updating tag: %w", err)

+ 6 - 10
cli/cmd/v2/update_image.go

@@ -12,13 +12,12 @@ import (
 
 // UpdateImageInput is the input for the UpdateImage function
 type UpdateImageInput struct {
-	ProjectID               uint
-	ClusterID               uint
-	AppName                 string
-	DeploymentTargetName    string
-	Tag                     string
-	WaitForSuccessfulUpdate bool
-	Client                  api.Client
+	ProjectID            uint
+	ClusterID            uint
+	AppName              string
+	DeploymentTargetName string
+	Tag                  string
+	Client               api.Client
 }
 
 // UpdateImage updates the image of an application
@@ -38,9 +37,6 @@ func UpdateImage(ctx context.Context, input UpdateImageInput) (string, error) {
 	}
 
 	triggeredBackgroundColor := color.FgGreen
-	if input.WaitForSuccessfulUpdate {
-		triggeredBackgroundColor = color.FgBlue
-	}
 
 	_, _ = color.New(triggeredBackgroundColor).Printf("Updated application %s to use tag \"%s\"\n", input.AppName, tag)
 	return resp.RevisionID, nil