Skip to content

Commit

Permalink
Fix sonar issue
Browse files Browse the repository at this point in the history
  • Loading branch information
artem-dudarev committed Dec 5, 2024
1 parent 437c42d commit 30e8f18
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ public static async Task ApplyRewardsAsync(this CartAggregate aggregate, ICollec
{
var availableGifts = (await aggregate.GetAvailableGiftsAsync(rewards)).ToList();

if (availableGifts.Any())
if (availableGifts.Count > 0)
{
var newGiftItemIds = availableGifts.Where(x => !x.HasLineItem).Select(x => x.Id).ToList();
await aggregate.AddGiftItemsAsync(newGiftItemIds, availableGifts); //add new items to cart
Expand Down

0 comments on commit 30e8f18

Please sign in to comment.