Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master' into release
Browse files Browse the repository at this point in the history
  • Loading branch information
ryangribble committed Jan 16, 2017
2 parents 7c7ffb8 + 01a2d97 commit d76e570
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Octokit.Tests/Http/ConnectionTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ public async Task AbuseExceptionContainsTheRetryAfterHeaderAmount()
Assert.Equal(45, exception.RetryAfterSeconds);
}

[Fact(Skip = "Fails due to https://github.com/octokit/octokit.net/issues/1529. The message is empty but the default message isn't displayed. However, this isn't due to the introduction of AbuseException, but rather something else.")]
[Fact]
public async Task ThrowsAbuseExceptionWithDefaultMessageForUnsafeAbuseResponse()
{
string messageText = string.Empty;
Expand Down
7 changes: 6 additions & 1 deletion Octokit/Exceptions/ApiException.cs
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,12 @@ protected string ApiErrorMessageSafe
{
get
{
return ApiError != null ? ApiError.Message : null;
if (ApiError != null && !string.IsNullOrWhiteSpace(ApiError.Message))
{
return ApiError.Message;
}

return null;
}
}

Expand Down

0 comments on commit d76e570

Please sign in to comment.