Skip to content

Commit

Permalink
combined output dir check with the previous section
Browse files Browse the repository at this point in the history
  • Loading branch information
k4yt3x authored Apr 14, 2022
1 parent 22f656b commit a1d750e
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions video2x/video2x.py
Original file line number Diff line number Diff line change
Expand Up @@ -586,10 +586,8 @@ def main() -> int:
if not args.input.is_file():
logger.critical("Input path is not a file")
return 1

# Output file won't exist yet, but the parent directory should.
if not args.output.parent.exists():
logger.critical(f"Output directory does not exist: {args.output}")
logger.critical(f"Output directory does not exist: {args.output.parent}")
return 1

# set logger level
Expand Down

0 comments on commit a1d750e

Please sign in to comment.