mirror of https://github.com/MISP/misp-modules
- content was already a wand.obj
parent
90f2fe9d19
commit
2f5dd9928e
|
@ -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")
|
||||
|
|
Loading…
Reference in New Issue