//GET /Song/DeleteFavorite/ public ActionResult DeleteFavorite(string artist, string name) { ViewUser user; if (Session["user"] != null && Session["user"].GetType() == (typeof(ViewUser))) { user = ((ViewUser)Session["user"]); } else { return(Redirect("/")); } Neo4jDataProvider dbNeo4j = new Neo4jDataProvider(); RedisDataProvider dbRedis = new RedisDataProvider(); dbNeo4j.SongRemoveFromFavorites(name, artist, user.name); string uri = ""; if (Request.UrlReferrer != null) { uri = Request.UrlReferrer.ToString(); } return(Redirect(uri)); }