From 3e6f43a4a68e72f96d12e4a2a8c81566fb07c7d3 Mon Sep 17 00:00:00 2001 From: ngfrolov Date: Tue, 5 Dec 2023 14:07:56 +0500 Subject: [PATCH] Fix ReportController.GetReportsDateRangeAsync return 204 on default values --- AsbCloudWebApi/Controllers/ReportController.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/AsbCloudWebApi/Controllers/ReportController.cs b/AsbCloudWebApi/Controllers/ReportController.cs index ebd6a690..e9194ad6 100644 --- a/AsbCloudWebApi/Controllers/ReportController.cs +++ b/AsbCloudWebApi/Controllers/ReportController.cs @@ -149,7 +149,10 @@ namespace AsbCloudWebApi.Controllers if (wellReportsDatesRange is null) return NoContent(); - + + if (wellReportsDatesRange.From == wellReportsDatesRange.To) + return NoContent(); + return Ok(wellReportsDatesRange); } }