diff options
Diffstat (limited to 'MediaBrowser.Api/Library/LibraryService.cs')
| -rw-r--r-- | MediaBrowser.Api/Library/LibraryService.cs | 37 |
1 files changed, 1 insertions, 36 deletions
diff --git a/MediaBrowser.Api/Library/LibraryService.cs b/MediaBrowser.Api/Library/LibraryService.cs index 0e5a3ab25..802df5cca 100644 --- a/MediaBrowser.Api/Library/LibraryService.cs +++ b/MediaBrowser.Api/Library/LibraryService.cs @@ -1,5 +1,4 @@ -using MediaBrowser.Common.Extensions; -using MediaBrowser.Controller.Channels; +using MediaBrowser.Controller.Channels; using MediaBrowser.Controller.Dto; using MediaBrowser.Controller.Entities; using MediaBrowser.Controller.Entities.Audio; @@ -35,21 +34,6 @@ namespace MediaBrowser.Api.Library public string Id { get; set; } } - [Route("/Videos/{Id}/Subtitles/{Index}", "GET")] - [Api(Description = "Gets an external subtitle file")] - public class GetSubtitle - { - /// <summary> - /// Gets or sets the id. - /// </summary> - /// <value>The id.</value> - [ApiMember(Name = "Id", Description = "Item Id", IsRequired = true, DataType = "string", ParameterType = "path", Verb = "GET")] - public string Id { get; set; } - - [ApiMember(Name = "Index", Description = "The subtitle stream index", IsRequired = true, DataType = "int", ParameterType = "path", Verb = "GET")] - public int Index { get; set; } - } - /// <summary> /// Class GetCriticReviews /// </summary> @@ -305,25 +289,6 @@ namespace MediaBrowser.Api.Library return ToStaticFileResult(item.Path); } - public object Get(GetSubtitle request) - { - var subtitleStream = _itemRepo.GetMediaStreams(new MediaStreamQuery - { - - Index = request.Index, - ItemId = new Guid(request.Id), - Type = MediaStreamType.Subtitle - - }).FirstOrDefault(); - - if (subtitleStream == null) - { - throw new ResourceNotFoundException(); - } - - return ToStaticFileResult(subtitleStream.Path); - } - /// <summary> /// Gets the specified request. /// </summary> |
