mirror of
https://github.com/jrnl-org/jrnl.git
synced 2025-05-10 16:48:31 +02:00
Clean up method comment and add type hints
This commit is contained in:
parent
b0da4e11b6
commit
36b9b79a69
1 changed files with 1 additions and 4 deletions
|
@ -91,10 +91,7 @@ def parse(
|
|||
return date
|
||||
|
||||
|
||||
def is_valid_date(year, month, day):
|
||||
"""
|
||||
Checks if a string can be parsed as a date
|
||||
"""
|
||||
def is_valid_date(year: int, month: int, day: int) -> bool:
|
||||
try:
|
||||
datetime.datetime(year, month, day)
|
||||
return True
|
||||
|
|
Loading…
Add table
Reference in a new issue