Replaces the custom EmptyRequest with explicit API client operations

Removes the Web-specific EmptyRequest record struct and keeps FastEndpoints.EmptyRequest only as an endpoint request DTO.

Adds bodyless and response-ignoring client overloads, centralizes request construction and response disposal, and separates stale-session failures from generic 404 responses.

Updates the API client stub and tests, including regression coverage for non-empty response bodies, overload selection, and crafted theme asset paths.
This commit is contained in:
BinaryAlley committed 2026-11-20 08:52:59 +02:00
1 parent c1dd08706c
commit 0a86f1a70b
70 files changed
+679 -384

No files matched your search

@@ -0,0 +1,23 @@
#region ========================================================================= USING =====================================================================================
using Lumina.Presentation.Web.Common.DTO.Common;
using System.Net;
#endregion
namespace Lumina.Presentation.Web.Common.Exceptions;
/// <summary>
/// Exception for an unsuccessful current-user authorization check, which means that the stored session refers to a user the API no longer knows.
/// </summary>
public class CurrentUserAuthorizationException : ApiException
{
/// <summary>
/// Initializes a new instance of the <see cref="CurrentUserAuthorizationException"/> class.
/// </summary>
/// <param name="problemDetails">The problem details object returned by the API.</param>
/// <param name="httpStatusCode">The HTTP status code returned by the API.</param>
/// <param name="requestPath">The absolute path of the API endpoint that produced this exception.</param>
public CurrentUserAuthorizationException(ProblemDetailsDto? problemDetails, HttpStatusCode httpStatusCode, string? requestPath = null)
: base(problemDetails, httpStatusCode, requestPath)
{
}
}