Skip to content

Commit e0ca2d7

Browse files
committed
feat(volume): add async output handling
1 parent 386dc10 commit e0ca2d7

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

internal/cmd/volume/create/create.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,11 @@ func outputResult(p *print.Printer, model *inputModel, projectLabel string, volu
184184
return fmt.Errorf("volume response is empty")
185185
}
186186
return p.OutputResult(model.OutputFormat, volume, func() error {
187-
p.Outputf("Created volume for project %q.\nVolume ID: %s\n", projectLabel, utils.PtrString(volume.Id))
187+
operationState := "Created"
188+
if model.Async {
189+
operationState = "Triggered creation of"
190+
}
191+
p.Outputf("%s volume for project %q.\nVolume ID: %s\n", operationState, projectLabel, utils.PtrString(volume.Id))
188192
return nil
189193
})
190194
}

0 commit comments

Comments
 (0)