예제 #1
0
        public void Like(int key)
        {
            Post updateThisPost = repo.GetT(key);

            updateThisPost.Rating++;
            repo.Update(updateThisPost);
        }
예제 #2
0
        public void IncreaseVote(int id)
        {
            var forVoting = GetPostById(id);

            forVoting.NumberOfVotes++;
            redditRepository.Update(forVoting);
        }
예제 #3
0
 public void UpdatePost(Post post)
 {
     redditRepository.Update(post);
 }