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 e2644c9

Browse files
crai0Lee-W
authored andcommitted
refactor(commit): use Optional[str] instead of str | None
1 parent d3f2b68 commit e2644c9

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

‎commitizen/commands/commit.py‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
import contextlib
22
import os
33

4+
from typing import Optional
5+
46
import questionary
57

68
from commitizen import factory, git, out
@@ -33,7 +35,7 @@ def __init__(self, config: BaseConfig, arguments: dict):
3335
self.arguments = arguments
3436
self.temp_file: str = get_backup_file_path()
3537

36-
def read_backup_message(self) -> str|None:
38+
def read_backup_message(self) -> Optional[str]:
3739
# Check the commit backup file exists
3840
if not os.path.isfile(self.temp_file):
3941
return None

0 commit comments

Comments
(0)

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