Blog.Logic.Core.PostsLogic.GetMorePostsByUser C# (CSharp) Method

GetMorePostsByUser() public method

public GetMorePostsByUser ( int userId, int skip ) : List
userId int
skip int
return List
        public List<Post> GetMorePostsByUser(int userId, int skip)
        {
            var posts = new List<Post>();
            try
            {
                var db = _postRepository.GetMorePostsByUser(userId, 5, skip).ToList();
                db.ForEach(a => posts.Add(PostMapper.ToDto(a)));
                posts.ForEach(a => GetPostProperties(a));
            }
            catch (Exception ex)
            {
                throw new BlogException(ex.Message, ex.InnerException);
            }
            return posts;
        }