Skip to content

Commit

Permalink
fix: make status a getter/setter
Browse files Browse the repository at this point in the history
  • Loading branch information
mdonnalley committed Dec 17, 2021
1 parent 9cf2069 commit 441c55a
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/ux.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,17 @@ export class Spinner {
/**
* Set the status of the current spinner.
*/
public status(status: string): void {
public set status(status: string | undefined) {
if (!this.jsonEnabled) cli.action.status = status;
}

/**
* Get the status of the current spinner.
*/
public get status(): string | undefined {
return cli.action.status;
}

/**
* Pause the spinner on the console.
*/
Expand Down

0 comments on commit 441c55a

Please sign in to comment.