Skip to content

Commit

Permalink
feat(server): add support for the tif extension (immich-app#3743)
Browse files Browse the repository at this point in the history
  • Loading branch information
jrasm91 authored Aug 17, 2023
1 parent 8ba338f commit cdb4536
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion server/src/domain/domain.constant.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ describe('mimeTypes', () => {
{ mimetype: 'image/sr2', extension: '.sr2' },
{ mimetype: 'image/srf', extension: '.srf' },
{ mimetype: 'image/srw', extension: '.srw' },
{ mimetype: 'image/tiff', extension: '.tif' },
{ mimetype: 'image/tiff', extension: '.tiff' },
{ mimetype: 'image/webp', extension: '.webp' },
{ mimetype: 'image/x-adobe-dng', extension: '.dng' },
Expand Down Expand Up @@ -82,7 +83,7 @@ describe('mimeTypes', () => {
{ mimetype: 'video/x-ms-wmv', extension: '.wmv' },
{ mimetype: 'video/x-msvideo', extension: '.avi' },
]) {
it(`should map ${extension} to ${mimetype}`, async () => {
it(`should map ${extension} to ${mimetype}`, () => {
expect({ ...mimeTypes.image, ...mimeTypes.video }[extension]).toContain(mimetype);
});
}
Expand Down
1 change: 1 addition & 0 deletions server/src/domain/domain.constant.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ const image: Record<string, string[]> = {
'.sr2': ['image/sr2', 'image/x-sony-sr2'],
'.srf': ['image/srf', 'image/x-sony-srf'],
'.srw': ['image/srw', 'image/x-samsung-srw'],
'.tif': ['image/tiff'],
'.tiff': ['image/tiff'],
'.webp': ['image/webp'],
'.x3f': ['image/x3f', 'image/x-sigma-x3f'],
Expand Down

0 comments on commit cdb4536

Please sign in to comment.