Fix EZP-23390: Legacy IO loads whole file to get mime type with FS cluster handler

Todo:
- [ ] Get legacy patch merged and change composer.json to reflect that before merging this