in src/YouTrackSharp/TimeTracking/WorkItem.cs [43:56]
internal static WorkItem FromApiEntity(IssueWorkItem entity)
{
return new WorkItem()
{
Id = entity.Id,
Date = entity.Date?.TimestampToDateTime(),
Duration = entity.Duration.Minutes.MinutesToTimeSpan(),
Description = entity.Text,
WorkType = entity.Type == null ? null : WorkType.FromApiEntity(entity.Type),
Author = entity.Author == null ? null : Author.FromApiEntity(entity.Author),
Created = entity.Created?.TimestampToDateTime(),
Updated = entity.Updated?.TimestampToDateTime()
};
}