Skip to content

Commit

Permalink
Fix convert_start_end_from_negative()
Browse files Browse the repository at this point in the history
The application will malfunctioning if --start-chapter exists and --end-chapter don't (vice versa)
  • Loading branch information
mansuf committed Jun 15, 2024
1 parent 63577e9 commit 82a4add
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions mangadex_downloader/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -376,14 +376,9 @@ def convert_start_end_from_negative(start_num, end_num, data):
- "--end-page"
"""

if start_num is None and end_num is None:
if start_num is None or end_num is None:
return start_num, end_num

if start_num is None:
start_num = 0
if end_num is None:
end_num = 0

if start_num >= 0 and end_num >= 0:
return start_num, end_num

Expand Down

0 comments on commit 82a4add

Please sign in to comment.