Ensured UTC is used

This commit is contained in:
Khwezi Mngoma
2026-05-15 08:37:58 +02:00
parent 4523ef6151
commit 65687d231e
9 changed files with 24 additions and 24 deletions
@@ -1,7 +1,6 @@
using LiteCharms.Features.Extensions;
using LiteCharms.Features.Shop.Postgres;
using LiteCharms.Features.Shop.ShoppingCarts.Models;
using static LiteCharms.Features.Extensions.Timezones;
namespace LiteCharms.Features.Shop.ShoppingCarts;
@@ -284,7 +283,7 @@ public class ShoppingCartService(IDbContextFactory<ShopDbContext> contextFactory
return Result.Fail($"Shopping cart item could not be found with id {shoppingCartItemId}");
item.Quantity = quantity;
item.UpdatedAt = SouthAfricanTimeZone.UtcNow();
item.UpdatedAt = DateTime.UtcNow;
return await context.SaveChangesAsync(cancellationToken) > 0
? Result.Ok()