$pdf->setLayerMethod(NULL) ruins some PDFs

Created on 5 November 2024, about 2 months ago

Problem/Motivation

Everything worked well on version 5.6.0. After updating to 6.0.1, some PDFs started to produce incorrect thumbnails.

After some debugging I have found that $pdf->setLayerMethod(NULL) is the reason. When it's commented out, the thumbnail looks good again:

I was really curious why it worked on version 5.6.0. It turned out that it worked by accident 😅 This line was always erroring (imagick couldn't read the doc), and the catch block did not include setLayerMethod.

Steps to reproduce

Try to make a thumbnail for the attached invoicesample.pdf file.

Proposed resolution

Delete $pdf->setLayerMethod(NULL)?

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Active

Version

6.0

Component

Code

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024