From: gu.martinm@gmail.com Date: Sun, 17 Aug 2014 09:09:13 +0000 (+0200) Subject: WeatherInformation WP8: X-Git-Url: https://git.gumartinm.name/?a=commitdiff_plain;h=9f748c2820bfc16eda96f6117f40d28082a0a148;p=CSharpForFun%2F.git WeatherInformation WP8: Using ConfigureAwait(false) as much as possible --- diff --git a/WindowsPhone/WeatherInformation/WeatherInformation/Model/Services/CustomHTTPClient.cs b/WindowsPhone/WeatherInformation/WeatherInformation/Model/Services/CustomHTTPClient.cs index 28cd3e1..f93fc75 100644 --- a/WindowsPhone/WeatherInformation/WeatherInformation/Model/Services/CustomHTTPClient.cs +++ b/WindowsPhone/WeatherInformation/WeatherInformation/Model/Services/CustomHTTPClient.cs @@ -54,7 +54,7 @@ namespace WeatherInformation.Model.Services using (HttpContent contentRESULT = response.Content) { - return await this.ReadResponseAsync(contentRESULT); + return await this.ReadResponseAsync(contentRESULT).ConfigureAwait(false); } } } @@ -72,10 +72,10 @@ namespace WeatherInformation.Model.Services encoding = Encoding.UTF8; } - using (Stream stream = await content.ReadAsStreamAsync()) + using (Stream stream = await content.ReadAsStreamAsync().ConfigureAwait(false)) using (StreamReader streamReader = new StreamReader(stream, encoding)) { - return await streamReader.ReadToEndAsync(); + return await streamReader.ReadToEndAsync().ConfigureAwait(false); } } }