Skip to content

Commit 6d9e0d1

Browse files
authored
Merge branch 'main' into patch-1
2 parents 676099c + 1ab1377 commit 6d9e0d1

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/utils.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,6 +250,7 @@ def replace_image(page: pymupdf.Page, xref: int, *, filename=None, pixmap=None,
250250
# new image insertion has created a new /Contents source,
251251
# which we will set to spaces now
252252
doc.update_stream(last_contents_xref, b" ")
253+
page._image_info = None # clear cache of extracted image information
253254

254255

255256
def delete_image(page: pymupdf.Page, xref: int):

0 commit comments

Comments
 (0)