diff options
| author | David <daullmer@gmail.com> | 2020-06-18 18:52:01 +0200 |
|---|---|---|
| committer | David <daullmer@gmail.com> | 2020-06-18 18:52:01 +0200 |
| commit | 762eeb51e66368e5f6fdede7b6fab84ea5859107 (patch) | |
| tree | c9d18360013b149f204e0d6e4e60292ce45d54f4 /Jellyfin.Api/Controllers/SubtitleController.cs | |
| parent | 713ae7ae363cafd95bd93bfd69b4ac7ab5b9b32b (diff) | |
| parent | 522e44de59a8661a859f6a373e495a9e0e8d13ff (diff) | |
Merge remote-tracking branch 'remotes/upstream/api-migration' into api-user
Diffstat (limited to 'Jellyfin.Api/Controllers/SubtitleController.cs')
| -rw-r--r-- | Jellyfin.Api/Controllers/SubtitleController.cs | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/Jellyfin.Api/Controllers/SubtitleController.cs b/Jellyfin.Api/Controllers/SubtitleController.cs index 97df8c60d..69b83379d 100644 --- a/Jellyfin.Api/Controllers/SubtitleController.cs +++ b/Jellyfin.Api/Controllers/SubtitleController.cs @@ -1,4 +1,3 @@ -#nullable enable #pragma warning disable CA1801 using System; @@ -110,7 +109,7 @@ namespace Jellyfin.Api.Controllers /// <response code="200">Subtitles retrieved.</response> /// <returns>An array of <see cref="RemoteSubtitleInfo"/>.</returns> [HttpGet("/Items/{id}/RemoteSearch/Subtitles/{language}")] - [Authorize] + [Authorize(Policy = Policies.DefaultAuthorization)] [ProducesResponseType(StatusCodes.Status200OK)] public async Task<ActionResult<IEnumerable<RemoteSubtitleInfo>>> SearchRemoteSubtitles( [FromRoute] Guid id, @@ -130,7 +129,7 @@ namespace Jellyfin.Api.Controllers /// <response code="204">Subtitle downloaded.</response> /// <returns>A <see cref="NoContentResult"/>.</returns> [HttpPost("/Items/{id}/RemoteSearch/Subtitles/{subtitleId}")] - [Authorize] + [Authorize(Policy = Policies.DefaultAuthorization)] [ProducesResponseType(StatusCodes.Status204NoContent)] public async Task<ActionResult> DownloadRemoteSubtitles( [FromRoute] Guid id, @@ -160,7 +159,7 @@ namespace Jellyfin.Api.Controllers /// <response code="200">File returned.</response> /// <returns>A <see cref="FileStreamResult"/> with the subtitle file.</returns> [HttpGet("/Providers/Subtitles/Subtitles/{id}")] - [Authorize] + [Authorize(Policy = Policies.DefaultAuthorization)] [ProducesResponseType(StatusCodes.Status200OK)] [Produces(MediaTypeNames.Application.Octet)] public async Task<ActionResult> GetRemoteSubtitles([FromRoute] string id) @@ -250,7 +249,7 @@ namespace Jellyfin.Api.Controllers /// <response code="200">Subtitle playlist retrieved.</response> /// <returns>A <see cref="FileContentResult"/> with the HLS subtitle playlist.</returns> [HttpGet("/Videos/{id}/{mediaSourceId}/Subtitles/{index}/subtitles.m3u8")] - [Authorize] + [Authorize(Policy = Policies.DefaultAuthorization)] [ProducesResponseType(StatusCodes.Status200OK)] public async Task<ActionResult> GetSubtitlePlaylist( [FromRoute] Guid id, |
