Skip to content

Commit

Permalink
Merge branch 'master' into fix-integrated-tests-valerii
Browse files Browse the repository at this point in the history
  • Loading branch information
ValDekh authored Nov 18, 2023
2 parents 510a12a + 0230695 commit b84d738
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public async Task<Result<NewsDTOWithURLs>> Handle(GetNewsAndLinksByUrlQuery requ
{
string errorMsg = _stringLocalizerNo["NoNewsByEnteredUrl", url].Value;
_logger.LogError(request, errorMsg);
return Result.Fail(errorMsg);
return Result.Ok();
}

if (newsDTO.Image is not null)
Expand Down Expand Up @@ -95,7 +95,6 @@ public async Task<Result<NewsDTOWithURLs>> Handle(GetNewsAndLinksByUrlQuery requ
{
string errorMsg = _stringLocalizerNo["NoNewsByEnteredUrl", url].Value;
_logger.LogError(request, errorMsg);
return Result.Fail(errorMsg);
}

return Result.Ok(newsDTOWithUrls);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,10 @@ protected ActionResult HandleResult<T>(Result<T> result)
}

return (result.Value is null) ?

NotFound("Not Found") : Ok(result.Value);
}

return BadRequest(result.Reasons);
}
}

Check failure on line 42 in Streetcode/Streetcode.WebApi/Controllers/BaseApiController.cs

View workflow job for this annotation

GitHub Actions / sonarcloud_branch

Code should not contain trailing whitespace

Check failure on line 42 in Streetcode/Streetcode.WebApi/Controllers/BaseApiController.cs

View workflow job for this annotation

GitHub Actions / sonarcloud_branch

Code should not contain trailing whitespace
}

0 comments on commit b84d738

Please sign in to comment.