The Milkman
Why does FileUpload not respect ->rules() ?
I've made PR for this: https://github.com/filamentphp/filament/pull/13814
10 replies
Why does FileUpload not respect ->rules() ?
Yes, internally is fine I guess. But when uploading a WOFF / WOFF2 file, the front-end validation always says that the uploaded file is of the wrong format, because my browser tells Filepond that it's mimetype is
null
...
See this exellent reply on SO: https://stackoverflow.com/a/77856904/281535010 replies
Why does FileUpload not respect ->rules() ?
Well, serverside validation seems to fail too...
...because Laravel's validator expects an actual File or UploadedFile. And all we get from FileUpload/Filepond is this:
["c97b1b35-ebc0-48bf-8258-bedbd02c123c" => "01J48ZGS4EMBSFS4Z3HSMPF1P4.woff2"]
So no validation of possible...
10 replies