diff options
| author | Bond_009 <bond.009@outlook.com> | 2023-03-01 18:57:23 +0100 |
|---|---|---|
| committer | Bond_009 <bond.009@outlook.com> | 2023-03-14 12:05:49 +0100 |
| commit | d8ec3a5470fe602fab356c37720d38190aa713ef (patch) | |
| tree | cd45b3a6ccd0085666d84f8b71ca7606fb94f68a /Jellyfin.Api/Controllers/ChannelsController.cs | |
| parent | af611367c14e2d56e6346b03bda7d75ab6f04b96 (diff) | |
Reduce usage of GetAwaiter().GetResult()
Diffstat (limited to 'Jellyfin.Api/Controllers/ChannelsController.cs')
| -rw-r--r-- | Jellyfin.Api/Controllers/ChannelsController.cs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/Jellyfin.Api/Controllers/ChannelsController.cs b/Jellyfin.Api/Controllers/ChannelsController.cs index b5c4d8346..11c4ac376 100644 --- a/Jellyfin.Api/Controllers/ChannelsController.cs +++ b/Jellyfin.Api/Controllers/ChannelsController.cs @@ -52,7 +52,7 @@ public class ChannelsController : BaseJellyfinApiController /// <returns>An <see cref="OkResult"/> containing the channels.</returns> [HttpGet] [ProducesResponseType(StatusCodes.Status200OK)] - public ActionResult<QueryResult<BaseItemDto>> GetChannels( + public async Task<ActionResult<QueryResult<BaseItemDto>>> GetChannels( [FromQuery] Guid? userId, [FromQuery] int? startIndex, [FromQuery] int? limit, @@ -61,7 +61,7 @@ public class ChannelsController : BaseJellyfinApiController [FromQuery] bool? isFavorite) { userId = RequestHelpers.GetUserId(User, userId); - return _channelManager.GetChannels(new ChannelQuery + return await _channelManager.GetChannelsAsync(new ChannelQuery { Limit = limit, StartIndex = startIndex, @@ -69,7 +69,7 @@ public class ChannelsController : BaseJellyfinApiController SupportsLatestItems = supportsLatestItems, SupportsMediaDeletion = supportsMediaDeletion, IsFavorite = isFavorite - }); + }).ConfigureAwait(false); } /// <summary> |
