rails / marcel

Find the mime type of files, examining file, filename and declared type
Apache License 2.0
386 stars 67 forks source link

Regression fix: binary declared type should fall back to filename extension type #99

Closed jeremy closed 8 months ago

jeremy commented 8 months ago

The application/octet-stream content type is treated as a default rather than a specific declaration. We should check the filename extension for the more specific type in this case. If there's no extension, the type falls back to binary anyway.

Fixes regression in 1.0.2 → 1.0.3 introduced by #94.