Skip to content

Fix boolean received error in getFileInfo()#755

Merged
Sebbo94BY merged 1 commit into
6.xfrom
Fix-boolean-received-error-in-getFileInfo-function
May 10, 2026
Merged

Fix boolean received error in getFileInfo()#755
Sebbo94BY merged 1 commit into
6.xfrom
Fix-boolean-received-error-in-getFileInfo-function

Conversation

@Sebbo94BY
Copy link
Copy Markdown
Collaborator

@Sebbo94BY Sebbo94BY commented May 10, 2026

The change is in src/PhpImap/IncomingMailAttachment.php:132: getFileInfo() now routes the finfo lookup through a small helper and returns '' if detection fails instead of propagating false into a string return type. I also added tests/unit/IncomingMailAttachmentTest.php:1 with one regression test for the failure branch and one sanity check for the normal branch.

Solves #734

The change is in `src/PhpImap/IncomingMailAttachment.php:132: getFileInfo()` now
routes the finfo lookup through a small helper and returns `''` if detection
fails instead of propagating false into a string return type. I also added
`tests/unit/IncomingMailAttachmentTest.php:1` with one regression test for the
failure branch and one sanity check for the normal branch.
@Sebbo94BY Sebbo94BY merged commit 3c580e1 into 6.x May 10, 2026
0 of 9 checks passed
@Sebbo94BY Sebbo94BY deleted the Fix-boolean-received-error-in-getFileInfo-function branch May 10, 2026 18:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant