Skip to content

Commit

Permalink
fix: Issue with no-input on create (#655)
Browse files Browse the repository at this point in the history
  • Loading branch information
ankitpokhrel authored Aug 16, 2023
1 parent 533c415 commit 96b6219
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion internal/cmd/epic/create/create.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import (
"github.com/ankitpokhrel/jira-cli/internal/query"
"github.com/ankitpokhrel/jira-cli/pkg/jira"
"github.com/ankitpokhrel/jira-cli/pkg/surveyext"
"github.com/ankitpokhrel/jira-cli/pkg/tui"
)

const (
Expand Down Expand Up @@ -57,7 +58,7 @@ func create(cmd *cobra.Command, _ []string) {
params: params,
}

if cc.isNonInteractive() {
if cc.isNonInteractive() || cc.params.NoInput || tui.IsDumbTerminal() {
cc.params.NoInput = true

if cc.isMandatoryParamsMissing() {
Expand Down
3 changes: 2 additions & 1 deletion internal/cmd/issue/create/create.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import (
"github.com/ankitpokhrel/jira-cli/internal/query"
"github.com/ankitpokhrel/jira-cli/pkg/jira"
"github.com/ankitpokhrel/jira-cli/pkg/surveyext"
"github.com/ankitpokhrel/jira-cli/pkg/tui"
)

const (
Expand Down Expand Up @@ -72,7 +73,7 @@ func create(cmd *cobra.Command, _ []string) {
params: params,
}

if cc.isNonInteractive() {
if cc.isNonInteractive() || cc.params.NoInput || tui.IsDumbTerminal() {
cc.params.NoInput = true

if cc.isMandatoryParamsMissing() {
Expand Down

0 comments on commit 96b6219

Please sign in to comment.