1
0
Fork 0
mirror of https://github.com/immich-app/immich.git synced 2024-12-28 06:31:58 +00:00

feat: Add support for vob (#14590)

Add support for vob
This commit is contained in:
Lukas 2024-12-08 21:35:23 -05:00 committed by GitHub
parent e4b76e8efe
commit 1ba622adc9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 3 additions and 1 deletions

View file

@ -98,7 +98,7 @@ const validImages = [
'.x3f',
];
const validVideos = ['.3gp', '.avi', '.flv', '.m2ts', '.mkv', '.mov', '.mp4', '.mpg', '.mts', '.webm', '.wmv'];
const validVideos = ['.3gp', '.avi', '.flv', '.m2ts', '.mkv', '.mov', '.mp4', '.mpg', '.mts', '.vob', '.webm', '.wmv'];
const uploadTests = [
{

View file

@ -92,6 +92,7 @@ describe('mimeTypes', () => {
{ mimetype: 'video/x-matroska', extension: '.mkv' },
{ mimetype: 'video/x-ms-wmv', extension: '.wmv' },
{ mimetype: 'video/x-msvideo', extension: '.avi' },
{ mimetype: 'video/mpeg', extension: '.vob' },
]) {
it(`should map ${extension} to ${mimetype}`, () => {
expect({ ...mimeTypes.image, ...mimeTypes.video }[extension]).toContain(mimetype);

View file

@ -74,6 +74,7 @@ const video: Record<string, string[]> = {
'.mpeg': ['video/mpeg'],
'.mpg': ['video/mpeg'],
'.mts': ['video/mp2t'],
'.vob': ['video/mpeg'],
'.webm': ['video/webm'],
'.wmv': ['video/x-ms-wmv'],
};