- content was already a wand.obj

pull/199/head
Steve Clement 2018-06-30 11:38:26 +08:00
parent 90f2fe9d19
commit 2f5dd9928e
1 changed files with 1 additions and 1 deletions

View File

@ -42,7 +42,7 @@ def handler(q=False):
document = base64.b64decode(request["data"])
document = WImage(blob=document)
if document.format == 'PDF':
with WImage(blob=document) as pdf:
with document as pdf:
# Get number of pages
pages=len(pdf.sequence)
print(f"PDF with {pages} page(s) detected")