Specify image file return for GetItemImage2

This commit is contained in:
crobibero 2020-09-02 11:14:59 -06:00
parent ec2a5e4fb0
commit a698dab66f
2 changed files with 2 additions and 1 deletions

View File

@ -214,7 +214,7 @@ namespace Jellyfin.Api.Controllers
{
return Redirect("index.html?start=wizard#!/wizardstart.html");
}
return PhysicalFile(_resourceFileManager.GetResourcePath(basePath, path), MimeTypes.GetMimeType(path));
}

View File

@ -431,6 +431,7 @@ namespace Jellyfin.Api.Controllers
[HttpHead("Items/{itemId}/Images/{imageType}/{imageIndex}/{tag}/{format}/{maxWidth}/{maxHeight}/{percentPlayed}/{unplayedCount}", Name = "HeadItemImage2")]
[ProducesResponseType(StatusCodes.Status200OK)]
[ProducesResponseType(StatusCodes.Status404NotFound)]
[ProducesImageFile]
public async Task<ActionResult> GetItemImage2(
[FromRoute] Guid itemId,
[FromRoute] ImageType imageType,