Files
the-biergarten-app/WebAPI/Controllers/NotFoundController.cs
2026-01-13 00:13:39 -05:00

17 lines
429 B
C#

using Microsoft.AspNetCore.Mvc;
namespace WebAPI.Controllers
{
[ApiController]
[ApiExplorerSettings(IgnoreApi = true)]
[Route("error")] // ← required
public class NotFoundController : ControllerBase
{
[HttpGet("404")] // ← required
public IActionResult Handle404()
{
return NotFound(new { message = "Route not found." });
}
}
}