chore: init commit from GitHub
Some checks are pending
Deploy / update (push) Waiting to run
Build Project .NET / build (push) Waiting to run

This commit is contained in:
Lisoveliy
2025-05-12 19:44:33 +03:00
parent 11a3f40596
commit aebe654c38
107 changed files with 18953 additions and 403 deletions

View File

@@ -0,0 +1,22 @@
using Microsoft.AspNetCore.Mvc;
namespace SWAD.API.Controllers;
public abstract class ProblemsController : ControllerBase
{
protected ObjectResult BadRequest(string? detail)
{
return Problem(statusCode: StatusCodes.Status400BadRequest, title: "Bad request!", detail: detail);
}
protected ObjectResult NotFound(string? detail)
{
return Problem(statusCode: StatusCodes.Status404NotFound, title: "Not found :c", detail: detail);
}
protected ObjectResult BadGateway(string? detail)
{
return Problem(statusCode: StatusCodes.Status502BadGateway, title: "Some problems in other side, dude!",
detail: detail);
}
}