extension in uppercase
flaviomariano opened this issue · comments
Hi, i would like to be able to accept uppercased extensions, does it make sense to you? would it be possible to include this in the fileTypeAcceptable?
To accept uppercase letters also, the regex at src/index.js#L5 could be changed to
const extRegexp = /\.[a-zA-Z0-9]*$/;
This matches lowercase a-z, uppercase A-Z, and 0-9.
I wonder if this could/should allow more characters? e.g. asdf.ééé
- which is valid on most platforms (at least FAT32, NTFS, ext4). See https://en.wikipedia.org/wiki/Filename#Comparison_of_filename_limitations
Is line just trying to find that last part of the filename after the dot?
I'm happy to make a PR for the above, or a variant of it.
Thanks, good catch @shearer12345! Yes, it's basically just to get the file extension following the dot. PRs welcome, but otherwise I'll try and update this as soon as I get a chance.
Fixed via #25