Skip to content

Commit

Permalink
refactor: apply codacy suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
Guilherme Ferreira committed Dec 19, 2023
1 parent 22aef8c commit 31f5422
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public void Navigate(Action<TDomain> action, Predicate<TDbo> navigatingCondition
Guard.Argument(action).NotNull();
Guard.Argument(navigatingCondition).NotNull();

Navigate((domain, dbo) => action(domain), navigatingCondition);
Navigate((domain, _) => action(domain), navigatingCondition);
}

public void Navigate(Action<TDomain, TDbo> action, Predicate<TDbo> navigatingCondition)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public GetQueuesInput(RetryQueueStatus status,
{
Guard.Argument(itemsStatuses, nameof(itemsStatuses))
.DoesNotContain(stuckStatusFilter.ItemStatus,
(statuses, stuckStatus) =>
(_, _) =>
"The status list can't contain the status that can be considered as stuck.");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ public async Task<AddIfQueueExistsResult> AddIfQueueExistsAsync(IMessageContext
async () =>
{
return await AddIfQueueExistsAsync(
context,
new SaveToQueueInput(
new RetryQueueItemMessage(
context.ConsumerContext.Topic,
Expand Down Expand Up @@ -240,8 +239,7 @@ await Policy
throw new ArgumentException($"None of the handlers is able to update the input {updateItemInput.GetType()}");
}

private async Task<AddIfQueueExistsResult> AddIfQueueExistsAsync(IMessageContext context,
SaveToQueueInput saveToQueueInput)
private async Task<AddIfQueueExistsResult> AddIfQueueExistsAsync(SaveToQueueInput saveToQueueInput)
{
try
{
Expand Down
2 changes: 1 addition & 1 deletion src/KafkaFlow.Retry/Durable/RetryDurableMiddleware.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public async Task Invoke(IMessageContext context, MiddlewareDelegate next)
.Handle<Exception>(exception => _retryDurableDefinition.ShouldRetry(new RetryContext(exception)))
.WaitAndRetryAsync(
_retryDurableDefinition.RetryDurableRetryPlanBeforeDefinition.NumberOfRetries,
(retryNumber, c) =>
(retryNumber, _) =>
_retryDurableDefinition.RetryDurableRetryPlanBeforeDefinition.TimeBetweenTriesPlan(retryNumber),
(exception, waitTime, attemptNumber, c) =>
{
Expand Down

0 comments on commit 31f5422

Please sign in to comment.