dustin10 / VichUploaderBundle

A simple Symfony bundle to ease file uploads with ORM entities and ODM documents.
MIT License
1.83k stars 519 forks source link

publicUrl method check looks for wrong exception. #1445

Open wizhippo opened 4 months ago

wizhippo commented 4 months ago

https://github.com/dustin10/VichUploaderBundle/blame/ec9ad4b732c0d9063e6bf0221bb758ac405d64a2/src/Storage/FlysystemStorage.php#L123

This is catching the wrong exception.

It is throwing Symfony\Component\ErrorHandler\Error\UndefinedMethodError not FilesystemException

Seems this method is on Flysystem 3.6 onward. My deps currently use 2.x

To support 2.x should allow either exception?

Related to but not the same isuse: https://github.com/dustin10/VichUploaderBundle/pull/1444