Simplify the logic in $.type, thanks to jdalton for the suggesiton in 5d2be7e2.
Attach a file by drag & drop or click to upload