From 1ad990ad720931309afadd9f7912d66595dcc04e Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Sat, 19 Aug 2017 15:43:35 -0400 Subject: update live tv data transfer --- MediaBrowser.Api/PluginService.cs | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'MediaBrowser.Api/PluginService.cs') diff --git a/MediaBrowser.Api/PluginService.cs b/MediaBrowser.Api/PluginService.cs index eb95224b7..f6efe15e6 100644 --- a/MediaBrowser.Api/PluginService.cs +++ b/MediaBrowser.Api/PluginService.cs @@ -23,7 +23,7 @@ namespace MediaBrowser.Api /// [Route("/Plugins", "GET", Summary = "Gets a list of currently installed plugins")] [Authenticated] - public class GetPlugins : IReturn> + public class GetPlugins : IReturn { public bool? IsAppStoreEnabled { get; set; } } @@ -195,14 +195,13 @@ namespace MediaBrowser.Api /// System.Object. public async Task Get(GetPlugins request) { - var result = _appHost.Plugins.OrderBy(p => p.Name).Select(p => p.GetPluginInfo()).ToList(); + var result = _appHost.Plugins.OrderBy(p => p.Name).Select(p => p.GetPluginInfo()).ToArray(); var requireAppStoreEnabled = request.IsAppStoreEnabled.HasValue && request.IsAppStoreEnabled.Value; // Don't fail just on account of image url's try { - var packages = (await _installationManager.GetAvailablePackagesWithoutRegistrationInfo(CancellationToken.None)) - .ToList(); + var packages = (await _installationManager.GetAvailablePackagesWithoutRegistrationInfo(CancellationToken.None)); foreach (var plugin in result) { @@ -223,7 +222,7 @@ namespace MediaBrowser.Api return pkg != null && pkg.enableInAppStore; }) - .ToList(); + .ToArray(); } } catch @@ -232,7 +231,7 @@ namespace MediaBrowser.Api // Play it safe here if (requireAppStoreEnabled) { - result = new List(); + result = new PluginInfo[] { }; } } -- cgit v1.2.3