Jaaneek / useFilePicker

Simple react hook to open browser file selector.

Home Page:https://use-file-picker.vercel.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

File size validation is bugged for multiple file select in latest version

ls-sergey-uss opened this issue · comments

When selecting multiple files it would appear that only the first one is validated for size.
Im attaching a demo where if I select a file exceeding maxFileSize its not added to plainFiles and error is produced. However if my first file in multi selection is smaller than maxFileSize the whole bunch is added and no error is produced.

Sandbox

Demo

Screen.Recording.2022-07-27.at.1.26.31.PM.mov

Perhaps worth mentioning that version 1.0.0 doesnt appear to have this issue.

Thanks for reporting it, I can check it in few days, maybe someone else can take a look @MrKampla @GitKokoszka.

Yesterday, we released version 1.5.1 containing a fix for this issue. Closing the thread.