diff --git a/.changelog/24054.txt b/.changelog/24054.txt new file mode 100644 index 000000000..448f43df7 --- /dev/null +++ b/.changelog/24054.txt @@ -0,0 +1,3 @@ +```release-note:bug +cli: Fixed a bug in job status command where -t would act as though -json was also set +``` diff --git a/command/job_status.go b/command/job_status.go index 4de0d6e19..0f444646c 100644 --- a/command/job_status.go +++ b/command/job_status.go @@ -173,7 +173,7 @@ func (c *JobStatusCommand) Run(args []string) int { return 1 } - out, err := Format(true, c.tmpl, jsonJobs) + out, err := Format(c.json, c.tmpl, jsonJobs) if err != nil { c.Ui.Error(err.Error()) return 1 @@ -220,7 +220,7 @@ func (c *JobStatusCommand) Run(args []string) int { return 1 } - out, err := Format(true, c.tmpl, jsonJobs) + out, err := Format(c.json, c.tmpl, jsonJobs) if err != nil { c.Ui.Error(err.Error()) return 1