Commit 415a693
Fix RAW images file type detection
For Sony and Canon Raw file formats. They are based on the tiff format
and have the same magic number data so they are incorrectly classified
as tiff images.
Defining them as subtypes of tiff solves this issue:
```ruby
Marcel::MimeType.for Pathname.new("/Users/afcapel/Downloads/RAW_SONY_ILCE-7M2.ARW"), name: "/Users/afcapel/Downloads/RAW_SONY_ILCE-7M2.ARW"
=> "image/x-raw-sony"
```1 parent ccd4be5 commit 415a693
File tree
3 files changed
+3
-0
lines changed- lib/marcel/mime_type
- test/fixtures/name/image
- x-raw-canon
- x-raw-sony
3 files changed
+3
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
46 | 49 | | |
47 | 50 | | |
48 | 51 | | |
| |||
Binary file not shown.
Binary file not shown.
0 commit comments