public IActionResult DeletePost(int id) { var idUser = aartistRepository.GetIdUserByUsurName(User.Identity.Name); var idArtist = aartistRepository.GetIdArtistByIdUser(idUser); aartistRepository.DeletePost(id, idArtist); return(RedirectToAction("MyPost")); }