Skip to content

Commit

Permalink
Test out MIME type fix.
Browse files Browse the repository at this point in the history
  • Loading branch information
mathewjordan committed Sep 1, 2023
1 parent 1a7c242 commit c68b72d
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/api/response/iiif/presentation-api/items.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,7 @@ function buildAnnotationBody(fileSet, workType) {
const body = {
id: buildAnnotationBodyId(fileSet, workType),
type: bodyType,
format: isAudioVideo(bodyType)
? "application/x-mpegurl"
: fileSet.mime_type,
format: fileSet.mime_type,
height: fileSet.height || 100,
width: fileSet.width || 100,
};
Expand Down Expand Up @@ -42,8 +40,8 @@ function buildImageService(representativeImageUrl) {
];
}

function isAudioVideo(workType) {
return ["Audio", "Video"].includes(workType);
function isAudioVideo(type) {
return ["Audio", "Video", "Sound"].includes(type);
}

function isImage(workType) {
Expand Down

0 comments on commit c68b72d

Please sign in to comment.