diff options
Diffstat (limited to 'MediaBrowser.Api/WeatherService.cs')
| -rw-r--r-- | MediaBrowser.Api/WeatherService.cs | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/MediaBrowser.Api/WeatherService.cs b/MediaBrowser.Api/WeatherService.cs index 930daa270..7c85d849d 100644 --- a/MediaBrowser.Api/WeatherService.cs +++ b/MediaBrowser.Api/WeatherService.cs @@ -32,11 +32,7 @@ namespace MediaBrowser.Api /// <returns>System.Object.</returns> public object Get(GetWeather request) { - var kernel = (Kernel) Kernel; - - var location = string.IsNullOrWhiteSpace(request.Location) ? kernel.Configuration.WeatherLocation : request.Location; - - var result = kernel.WeatherProviders.First().GetWeatherInfoAsync(location, CancellationToken.None).Result; + var result = Kernel.Instance.WeatherProviders.First().GetWeatherInfoAsync(request.Location, CancellationToken.None).Result; return ToOptimizedResult(result); } |
