better redirection

This commit is contained in:
Nicolas Constant 2022-12-25 18:57:31 -05:00
parent 0eb0aa3c5d
commit 27e735ca4d
No known key found for this signature in database
GPG key ID: 1E9F677FB01A5688

View file

@ -60,10 +60,9 @@ namespace BirdsiteLive.Controllers
}
return View("UserNotFound");
}
[Route("/@{id}")]
[Route("/users/{id}")]
[Route("/users/{id}/remote_follow")]
public async Task<IActionResult> Index(string id)
{
_logger.LogTrace("User Index: {Id}", id);
@ -143,6 +142,12 @@ namespace BirdsiteLive.Controllers
};
return View(displayableUser);
}
[Route("/users/{id}/remote_follow")]
public async Task<IActionResult> IndexRemoteFollow(string id)
{
return Redirect($"/users/{id}");
}
[Route("/@{id}/{statusId}")]
[Route("/users/{id}/statuses/{statusId}")]