internal static Comment FromApiEntity()

in src/YouTrackSharp/Issues/Comment.cs [19:34]


        internal static Comment FromApiEntity(IssueComment entity, bool wikify = false)
        {
            return new Comment()
            {
                Id = entity.Id,
                Author = entity.Author?.Login,
                AuthorFullName = entity.Author?.FullName,
                IssueId = entity.Issue?.IdReadable,
                IsDeleted = entity.Deleted ?? false,
                IsMarkdown = true,
                Text = wikify ? entity.TextPreview : entity.Text,
                Created = (entity.Created ?? 0).TimestampToDateTime(),
                Updated = (entity.Updated ?? 0).TimestampToDateTime(),
                PermittedGroup = entity.Visibility?.ToSinglePermittedGroup()
            };
        }