feat: Add input file existence check in PDF compression service and create test tools script
This commit is contained in:
@@ -59,6 +59,9 @@ def compress_pdf(
|
||||
input_path,
|
||||
]
|
||||
|
||||
if not os.path.exists(input_path):
|
||||
raise PDFCompressionError(f"Input file not found: {input_path}")
|
||||
|
||||
try:
|
||||
original_size = os.path.getsize(input_path)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user