Example #1
0
        public void RemoveMemberFromProject(int projectId, int memberId)
        {
            var project = _projectDAO.GetProjectById(projectId);
            var member  = _projectDAO.GetMemberById(memberId);

            if (member.User.Id == project.CreatedUser.Id)
            {
                throw new CheckedException("Cannot remove project's creator");
            }
            _projectDAO.DeleteMember(projectId, memberId);
        }