Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 56b113c

Browse files
bearomorphismLee-W
authored andcommitted
refactor(jira): refactor message
1 parent 6cbe580 commit 56b113c

File tree

1 file changed

+4
-11
lines changed

1 file changed

+4
-11
lines changed

‎commitizen/cz/jira/jira.py‎

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -43,18 +43,11 @@ def questions(self) -> list[CzQuestion]:
4343
},
4444
]
4545

46-
def message(self, answers: dict) -> str:
46+
def message(self, answers: dict[str, str]) -> str:
4747
return " ".join(
48-
filter(
49-
bool,
50-
[
51-
answers["message"],
52-
answers["issues"],
53-
answers["workflow"],
54-
answers["time"],
55-
answers["comment"],
56-
],
57-
)
48+
x
49+
for k in ("message", "issues", "workflow", "time", "comment")
50+
if (x := answers.get(k))
5851
)
5952

6053
def example(self) -> str:

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /