Skip to content

Commit

Permalink
fix: resolve PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
HamedSY committed Jul 28, 2024
1 parent d0aebe8 commit 844da6c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public async Task Handle_ShouldThrowsValidationException_WhenInputIsInvalid()
}

[Fact]
public async Task Handle_ShouldCallCreateFileAsync_AndInputsAreValid()
public async Task Handle_ShouldCallCreateFileAsync_WhenInputsAreValid()
{
// Arrange
_validator.RuleFor(x => x).Must(_ => true);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,8 @@ public async Task<ApiResponse<GetFileResponseDto>> Handle(GetFileCommand command
var owner = _options.Value.RepositoriesOwner;
var apiResponse = await _fileRestClient.GetFileAsync(owner, command.RepositoryName, command.FilePath, getFileRequest, cancellationToken)
.ConfigureAwait(false);
if (apiResponse?.Content != null)
await apiResponse.EnsureSuccessStatusCodeAsync();
if (apiResponse.Content is not null)
{
apiResponse.Content.Content = _contentDecoder.Base64Decode(apiResponse.Content.Content);
}
Expand Down

0 comments on commit 844da6c

Please sign in to comment.