aboutsummaryrefslogtreecommitdiff
path: root/MediaBrowser.Api/Movies/TrailersService.cs
diff options
context:
space:
mode:
Diffstat (limited to 'MediaBrowser.Api/Movies/TrailersService.cs')
-rw-r--r--MediaBrowser.Api/Movies/TrailersService.cs16
1 files changed, 3 insertions, 13 deletions
diff --git a/MediaBrowser.Api/Movies/TrailersService.cs b/MediaBrowser.Api/Movies/TrailersService.cs
index ed197911a..39c7b7f44 100644
--- a/MediaBrowser.Api/Movies/TrailersService.cs
+++ b/MediaBrowser.Api/Movies/TrailersService.cs
@@ -108,20 +108,10 @@ namespace MediaBrowser.Api.Movies
private async Task<QueryResult<BaseItem>> GetAllTrailers(User user)
{
- var trailerResult = await _channelManager.GetAllMediaInternal(new AllChannelMediaQuery
+ return _libraryManager.GetItems(new InternalItemsQuery(user)
{
- ContentTypes = new[] { ChannelMediaContentType.MovieExtra },
- ExtraTypes = new[] { ExtraType.Trailer },
- UserId = user.Id.ToString("N")
-
- }, CancellationToken.None).ConfigureAwait(false);
-
-
- return new QueryResult<BaseItem>
- {
- Items = trailerResult.Items,
- TotalRecordCount = trailerResult.TotalRecordCount
- };
+ IncludeItemTypes = new[] {typeof (Trailer).Name}
+ });
}
}
}