From 6ad5cedfabc7b2002d80479008fcb02c57c7c019 Mon Sep 17 00:00:00 2001 From: "Collin M. Barrett" Date: Fri, 5 Jul 2019 14:29:39 -0500 Subject: [PATCH] throw ApiException rather than returning new dummy instance of return type --- .../Infrastructure/Clients/AgentGitHubClient.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/FilterLists.Agent/Infrastructure/Clients/AgentGitHubClient.cs b/src/FilterLists.Agent/Infrastructure/Clients/AgentGitHubClient.cs index e22134e0f..89cd098b0 100644 --- a/src/FilterLists.Agent/Infrastructure/Clients/AgentGitHubClient.cs +++ b/src/FilterLists.Agent/Infrastructure/Clients/AgentGitHubClient.cs @@ -43,7 +43,7 @@ public async Task> GetAllIssues(RepositoryIssueRequest repo catch (ApiException ex) { _logger.LogError(ex, $"Failed getting all Issues{ExceptionMessageSuffix}"); - return new List(); + throw; } } @@ -57,7 +57,7 @@ public async Task CreateIssue(NewIssue newIssue) catch (ApiException ex) { _logger.LogError(ex, $"Failed creating Issue{ExceptionMessageSuffix}"); - return new Issue(); + throw; } } @@ -71,7 +71,7 @@ public async Task UpdateIssue(int issueNumber, IssueUpdate issueUpdate) catch (ApiException ex) { _logger.LogError(ex, $"Failed updating Issue{ExceptionMessageSuffix}"); - return new Issue(); + throw; } } }