From f665df578cc493858861addfc7abbe70d0ccf73a Mon Sep 17 00:00:00 2001 From: Aaron Po Date: Tue, 4 Aug 2026 06:19:10 -0400 Subject: [PATCH] update backend/shared docs --- .../Behaviors/ValidationBehavior.cs | 5 ++--- .../Shared/Shared.Contracts/ResponseBody.cs | 14 ++------------ 2 files changed, 4 insertions(+), 15 deletions(-) diff --git a/web/backend/Shared/Shared.Application/Behaviors/ValidationBehavior.cs b/web/backend/Shared/Shared.Application/Behaviors/ValidationBehavior.cs index e41d152b..05a21fcb 100644 --- a/web/backend/Shared/Shared.Application/Behaviors/ValidationBehavior.cs +++ b/web/backend/Shared/Shared.Application/Behaviors/ValidationBehavior.cs @@ -5,9 +5,8 @@ using MediatR; namespace Shared.Application.Behaviors; /// -/// MediatR pipeline behavior that runs all registered FluentValidation validators for a -/// request before invoking its handler, short-circuiting with a -/// when any validator reports failures. +/// MediatR pipeline behavior that runs registered FluentValidation validators before the handler, +/// throwing if any report failures. /// public class ValidationBehavior(IEnumerable> validators) : IPipelineBehavior diff --git a/web/backend/Shared/Shared.Contracts/ResponseBody.cs b/web/backend/Shared/Shared.Contracts/ResponseBody.cs index 4fc35c4f..2326814a 100644 --- a/web/backend/Shared/Shared.Contracts/ResponseBody.cs +++ b/web/backend/Shared/Shared.Contracts/ResponseBody.cs @@ -1,29 +1,19 @@ namespace Shared.Contracts; /// -/// Generic envelope used to wrap API responses that carry a data payload alongside a human-readable message. +/// Generic envelope used to wrap API responses that carry a data payload alongside a message. /// -/// The type of the data payload returned in the response. public record ResponseBody { - /// - /// A human-readable message describing the outcome of the request. - /// public required string Message { get; init; } - /// - /// The data payload associated with the response. - /// public required T Payload { get; init; } } /// -/// Envelope used to wrap API responses that carry only a human-readable message and no data payload. +/// Envelope used to wrap API responses that carry only a message and no data payload. /// public record ResponseBody { - /// - /// A human-readable message describing the outcome of the request. - /// public required string Message { get; init; } }