mirror of
https://github.com/bitwarden/server
synced 2025-12-23 19:53:40 +00:00
Revert filescoped (#2227)
* Revert "Add git blame entry (#2226)" This reverts commit239286737d. * Revert "Turn on file scoped namespaces (#2225)" This reverts commit34fb4cca2a.
This commit is contained in:
@@ -1,23 +1,24 @@
|
||||
using Microsoft.AspNetCore.Diagnostics;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
|
||||
namespace Bit.Admin.Controllers;
|
||||
|
||||
public class ErrorController : Controller
|
||||
namespace Bit.Admin.Controllers
|
||||
{
|
||||
[Route("/error")]
|
||||
public IActionResult Error(int? statusCode = null)
|
||||
public class ErrorController : Controller
|
||||
{
|
||||
var exceptionHandlerPathFeature = HttpContext.Features.Get<IExceptionHandlerPathFeature>();
|
||||
TempData["Error"] = HttpContext.Features.Get<IExceptionHandlerFeature>()?.Error.Message;
|
||||
[Route("/error")]
|
||||
public IActionResult Error(int? statusCode = null)
|
||||
{
|
||||
var exceptionHandlerPathFeature = HttpContext.Features.Get<IExceptionHandlerPathFeature>();
|
||||
TempData["Error"] = HttpContext.Features.Get<IExceptionHandlerFeature>()?.Error.Message;
|
||||
|
||||
if (exceptionHandlerPathFeature != null)
|
||||
{
|
||||
return Redirect(exceptionHandlerPathFeature.Path);
|
||||
}
|
||||
else
|
||||
{
|
||||
return Redirect("/Home");
|
||||
if (exceptionHandlerPathFeature != null)
|
||||
{
|
||||
return Redirect(exceptionHandlerPathFeature.Path);
|
||||
}
|
||||
else
|
||||
{
|
||||
return Redirect("/Home");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user