Skip to content

Latest commit

 

History

History
17 lines (13 loc) · 926 Bytes

extensions.md

File metadata and controls

17 lines (13 loc) · 926 Bytes

Extending Files

Here you will find information on how you can tune the behaviour of certain parts of the library.

Disabling file existence checks during file loading

Although in the majority of cases you will want the to check if the loaded files actually exist in their defined filesystems, there may be cases where that is unnecessary. For example: generating a financial report using entities that also have invoice scans that are irrelevant to the report itself. In this case the file checks not only slow down the process significantly, but can break it altogether if for any reason a file has gone missing.

In order to disable these checks, you can use the FSi\Component\Files\RuntimeConfigurator\FileExistenceChecksConfigurator interface. If you are using Symfony along with Flysystem, there is a service alias for that interface, so you can typehint the FileExistenceChecksConfigurator where you need it.