diff options
| author | jvoisin | 2022-05-15 18:57:27 +0200 |
|---|---|---|
| committer | jvoisin | 2022-05-15 18:57:27 +0200 |
| commit | 704367f91eebe6158399f930f725334db96de134 (patch) | |
| tree | 2a2f77e6e0b241b1120915df3608d961320072e7 /libmat2/parser_factory.py | |
| parent | 263971370931b1c5b8c49ab287e6d30e40d974e2 (diff) | |
Add support for HEIC files
Thanks to Maxime Morin ( https://www.maijin.fr/ )
for the patch.
Diffstat (limited to 'libmat2/parser_factory.py')
| -rw-r--r-- | libmat2/parser_factory.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libmat2/parser_factory.py b/libmat2/parser_factory.py index 9965432..a539d12 100644 --- a/libmat2/parser_factory.py +++ b/libmat2/parser_factory.py | |||
| @@ -11,6 +11,10 @@ T = TypeVar('T', bound='abstract.AbstractParser') | |||
| 11 | mimetypes.add_type('application/epub+zip', '.epub') | 11 | mimetypes.add_type('application/epub+zip', '.epub') |
| 12 | mimetypes.add_type('application/x-dtbncx+xml', '.ncx') # EPUB Navigation Control XML File | 12 | mimetypes.add_type('application/x-dtbncx+xml', '.ncx') # EPUB Navigation Control XML File |
| 13 | 13 | ||
| 14 | # This should be removed after we move to python3.10 | ||
| 15 | # https://github.com/python/cpython/commit/20a5b7e986377bdfd929d7e8c4e3db5847dfdb2d | ||
| 16 | mimetypes.add_type('image/heic', '.heic') | ||
| 17 | |||
| 14 | 18 | ||
| 15 | def __load_all_parsers(): | 19 | def __load_all_parsers(): |
| 16 | """ Loads every parser in a dynamic way """ | 20 | """ Loads every parser in a dynamic way """ |
