Skip to content

Commit

Permalink
Fixed config sample in the readme - usesystemdefault instead of usesy…
Browse files Browse the repository at this point in the history
…stemdefaults

Fixed Null Reference Exception in the RestSharpCommandProcessor - If there is a problem in the config or you set the account name to the full url instead of just the account name response.ResponseUri can be null
  • Loading branch information
Fergal O'Donnell authored and Fergal O'Donnell committed Nov 27, 2015
1 parent 47d2553 commit 32e1160
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion LeanKit.API.Client.Library/RestSharpCommandProcessor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ private static void ValidateResponse(IRestResponse<AsyncResponse> response,
throw new LeanKitAPIException("A failure occurred retrieving the response from the API.");
}

if (response.ResponseUri.Host != requestedResource.Host)
if (response.ResponseUri != null && response.ResponseUri.Host != requestedResource.Host)
{
throw new InvalidAPIResourceException();
}
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ Or, if more granular control of the proxy is required, it could look something l
```
<system.net>
<defaultProxy enabled="true" useDefaultCredentials="false">
<proxy usesystemdefaults="true" proxyaddress="http://192.168.1.10:3128" bypassonlocal="true" />
<proxy usesystemdefault="true" proxyaddress="http://192.168.1.10:3128" bypassonlocal="true" />
</defaultProxy>
</system.net>
```
Expand Down

0 comments on commit 32e1160

Please sign in to comment.