Exemplo n.º 1
0
        public api.getdelays.POCO.User DeleteFollowConnection(string userid, string idConnection)
        {
            IFollowedConnection followedConnection = new DALFollowedConnection();
            IUser userDAL = new DALUser();

            api.getdelays.POCO.User u = userDAL.GetUser(Convert.ToInt32(userid));
            if (u != null)
            {
                api.getdelays.POCO.FollowedConnection f = followedConnection.GetFollowedConnection(Convert.ToInt32(idConnection));
                followedConnection.DeleteFollowedConnection(f);
                u.followedConnections = followedConnection.GetFollowedConnections(u);
                return(u);
            }
            else
            {
                return(null);
            }
        }