From 029ea7919220fbc506898733caeb4370053051a7 Mon Sep 17 00:00:00 2001 From: TidusJar Date: Sat, 23 Nov 2024 22:02:58 +0000 Subject: [PATCH] fix(Fixed the UI not applying the correct timezone settings): :bug: --- src/Ombi/Controllers/V1/IdentityController.cs | 4 ---- src/Ombi/Startup.cs | 5 ++++- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/Ombi/Controllers/V1/IdentityController.cs b/src/Ombi/Controllers/V1/IdentityController.cs index 202e4bce3..1772cbecb 100644 --- a/src/Ombi/Controllers/V1/IdentityController.cs +++ b/src/Ombi/Controllers/V1/IdentityController.cs @@ -3,7 +3,6 @@ using System.Collections.Generic; using System.Linq; using System.Net; using System.Threading.Tasks; -using AutoMapper; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Identity; using Microsoft.AspNetCore.Mvc; @@ -14,7 +13,6 @@ using Ombi.Api.TheMovieDb.Models; using Ombi.Attributes; using Ombi.Core.Authentication; using Ombi.Core.Engine; -using Ombi.Core.Engine.Interfaces; using Ombi.Core.Helpers; using Ombi.Core.Models.UI; using Ombi.Core.Services; @@ -29,9 +27,7 @@ using Ombi.Schedule.Jobs.Ombi; using Ombi.Settings.Settings.Models; using Ombi.Settings.Settings.Models.Notifications; using Ombi.Store.Entities; -using Ombi.Store.Entities.Requests; using Ombi.Store.Repository; -using Ombi.Store.Repository.Requests; using IdentityResult = Microsoft.AspNetCore.Identity.IdentityResult; using OmbiIdentityResult = Ombi.Models.Identity.IdentityResult; diff --git a/src/Ombi/Startup.cs b/src/Ombi/Startup.cs index a04111cd3..b3d3307c1 100644 --- a/src/Ombi/Startup.cs +++ b/src/Ombi/Startup.cs @@ -87,7 +87,10 @@ namespace Ombi services.AddJwtAuthentication(); services.AddMvc() - .AddNewtonsoftJson(x => x.SerializerSettings.ReferenceLoopHandling = ReferenceLoopHandling.Ignore); + .AddNewtonsoftJson(x => { + x.SerializerSettings.ReferenceLoopHandling = ReferenceLoopHandling.Ignore; + x.SerializerSettings.DateTimeZoneHandling = DateTimeZoneHandling.Utc; + }); services.AddOmbiMappingProfile(); services.AddAutoMapper(expression => expression.AddCollectionMappers());