Esempio n. 1
0
        public void CreateCommentUser(string userId, int commentId)
        {
            var commentUser = new CommentUser {
                UserId = userId, CommentId = commentId
            };

            commentUserRepository.Add(commentUser);
            SaveCommentUser();
        }
Esempio n. 2
0
        public void CreateComment(Comment comment, string userId)
        {
            commentRepository.Add(comment);
            SaveComment();
            var commentUser = new CommentUser {
                UserId = userId, CommentId = comment.CommentId
            };

            commentUserRepository.Add(commentUser);
            SaveComment();
        }