public ActionResult Unfollow(string Id) { string id = Id; DataRepository helper = new DataRepository(); FollowConnection deleteMe2 = helper.getFollowConnectionFromUser(Session["Username"].ToString(),Id); helper.deleteConnection(deleteMe2); ViewData["Username"] = id; ViewData["Following"] = helper.getFollowingCount(Id); ViewData["FollowedBy"] = helper.getFollowedByCount(Id); return PartialView(); }
public ActionResult Unfollow(FollowConnection deleteMe) { DataRepository helper = new DataRepository(); helper.deleteConnection(deleteMe); return RedirectToAction("Index"); }