Bentham commited on
Commit
8c83b7e
·
verified ·
1 Parent(s): eb2e4f8

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +1 -1
main.py CHANGED
@@ -371,7 +371,7 @@ def convert_pptx_to_html(input_filename: str) -> str:
371
  html_content += f"<p>{text_content}</p>"
372
  else:
373
  html_content += f"<p>{text_content}</p>"
374
- elif shape.has_image:
375
  image = shape.image
376
  image_bytes = image.blob
377
  base64_encoded = base64.b64encode(image_bytes).decode('utf-8')
 
371
  html_content += f"<p>{text_content}</p>"
372
  else:
373
  html_content += f"<p>{text_content}</p>"
374
+ elif shape.shape_type == MSO_SHAPE_TYPE.PICTURE:
375
  image = shape.image
376
  image_bytes = image.blob
377
  base64_encoded = base64.b64encode(image_bytes).decode('utf-8')