extracting all the cross-platform setup of HttpMessageHandler into

a less awful class
This commit is contained in:
Brendan Forster
2015-05-31 19:23:39 +09:30
parent 5d0c8d6679
commit e5e4b4c8b0
12 changed files with 56 additions and 57 deletions
+1 -1
View File
@@ -92,7 +92,7 @@ namespace Octokit
/// <param name="credentialStore">Provides credentials to the client when making requests</param>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Microsoft.Reliability", "CA2000:Dispose objects before losing scope")]
public Connection(ProductHeaderValue productInformation, Uri baseAddress, ICredentialStore credentialStore)
: this(productInformation, baseAddress, credentialStore, new HttpClientAdapter(), new SimpleJsonSerializer())
: this(productInformation, baseAddress, credentialStore, new HttpClientAdapter(HttpMessageHandlerFactory.GetHandler), new SimpleJsonSerializer())
{
}