From a91a2d25d8d37630bdd66fe359d3a1cd5ba75a5d Mon Sep 17 00:00:00 2001 From: Vitalii Mikhailov Date: Sun, 25 Feb 2024 14:07:09 +0200 Subject: [PATCH] Fix --- src/BUTR.CrashReportServer/Controllers/ReportController.cs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/BUTR.CrashReportServer/Controllers/ReportController.cs b/src/BUTR.CrashReportServer/Controllers/ReportController.cs index 56f0a4e..a7312c2 100644 --- a/src/BUTR.CrashReportServer/Controllers/ReportController.cs +++ b/src/BUTR.CrashReportServer/Controllers/ReportController.cs @@ -168,7 +168,7 @@ public ActionResult> GetFilenameDates(ICollection filenamesWithExtension.Contains(x.FileId)) .AsEnumerable() - .Select(x => new FileMetadata(x.FileId, x.CrashReportId, x.Version, x.Created.ToUniversalTime()))); + .Select(x => new FileMetadata(x.FileId, x.CrashReportId, x.Version, x.Created))); } [Authorize] @@ -184,8 +184,8 @@ public ActionResult> GetNewCrashReportsDates([FromBody return BadRequest(); return Ok(_dbContext.IdEntities - .Where(x => x.Created.Ticks > body.DateTime.Ticks) - .Select(x => new FileMetadata(x.FileId, x.CrashReportId, x.Version, x.Created.ToUniversalTime()))); + .Where(x => x.Created > body.DateTime) + .Select(x => new FileMetadata(x.FileId, x.CrashReportId, x.Version, x.Created))); } [AllowAnonymous] @@ -208,6 +208,7 @@ public IActionResult SitemapIndex() }; return Ok(sitemap); } + [AllowAnonymous] [HttpGet("sitemap_{idx:int}.xml")] [Produces("application/xml")]