From d02267916129a6882485306a8c55adcbd0ec73a8 Mon Sep 17 00:00:00 2001 From: Kacper Tryniecki Date: Sat, 26 Oct 2024 21:54:14 +0200 Subject: [PATCH] Remove SimpleUploadDate --- YoutubeExplode/Bridge/SearchResponse.cs | 7 ------- YoutubeExplode/Search/SearchClient.cs | 3 --- YoutubeExplode/Search/VideoSearchResult.cs | 9 --------- 3 files changed, 19 deletions(-) diff --git a/YoutubeExplode/Bridge/SearchResponse.cs b/YoutubeExplode/Bridge/SearchResponse.cs index fb16f7f7..a1833cc9 100644 --- a/YoutubeExplode/Bridge/SearchResponse.cs +++ b/YoutubeExplode/Bridge/SearchResponse.cs @@ -122,13 +122,6 @@ internal class VideoData(JsonElement content) ?.StripNonDigit() ?.ParseLongOrNull(); - [Lazy] - public string? SimpleUploadDate => - content - .GetPropertyOrNull("publishedTimeText") - ?.GetPropertyOrNull("simpleText") - ?.GetStringOrNull(); - [Lazy] public IReadOnlyList Thumbnails => content diff --git a/YoutubeExplode/Search/SearchClient.cs b/YoutubeExplode/Search/SearchClient.cs index b0535ae1..83472383 100644 --- a/YoutubeExplode/Search/SearchClient.cs +++ b/YoutubeExplode/Search/SearchClient.cs @@ -72,8 +72,6 @@ public async IAsyncEnumerable> GetResultBatchesAsync( var viewCount = videoData.ViewCount ?? 0; - var simpleUploadDate = videoData.SimpleUploadDate; - var videoThumbnails = videoData .Thumbnails.Select(t => { @@ -108,7 +106,6 @@ public async IAsyncEnumerable> GetResultBatchesAsync( new Author(videoChannelId, videoChannelTitle), videoData.Duration, viewCount, - simpleUploadDate, videoThumbnails ); diff --git a/YoutubeExplode/Search/VideoSearchResult.cs b/YoutubeExplode/Search/VideoSearchResult.cs index 12c9ffcc..b01ea23e 100644 --- a/YoutubeExplode/Search/VideoSearchResult.cs +++ b/YoutubeExplode/Search/VideoSearchResult.cs @@ -15,7 +15,6 @@ public class VideoSearchResult( Author author, TimeSpan? duration, long viewCount, - string? simpleUploadDate, IReadOnlyList thumbnails ) : ISearchResult, IVideo { @@ -42,14 +41,6 @@ IReadOnlyList thumbnails /// public long ViewCount { get; } = viewCount; - /// - /// Video simplyfied upload date. - /// - /// - /// May be null if the video is planned premiere or live stream. - /// - public string? SimpleUploadDate { get; } = simpleUploadDate; - /// public IReadOnlyList Thumbnails { get; } = thumbnails;