1 parent 30f09c9 commit edbb8baCopy full SHA for edbb8ba
1 file changed
TelegramBot/MediaGet.cs
@@ -71,6 +71,7 @@ public class MediaGet
71
overrideOptions.Cookies = Config.cookiesFile;
72
73
DateTime lastProgressUpdate = DateTime.MinValue;
74
+ string lastStatusText = "";
75
var progress = new Progress<DownloadProgress>(p =>
76
{
77
if (DateTime.UtcNow - lastProgressUpdate < TimeSpan.FromMilliseconds(Config.videoGetDelay))
@@ -84,6 +85,9 @@ public class MediaGet
84
85
if (!string.IsNullOrEmpty(p.ETA))
86
statusText += $" ETA {p.ETA}";
87
88
+ if (statusText == lastStatusText) return;
89
+ lastStatusText = statusText;
90
+
91
if (Config.showVideoDownloadProgress)
92
Log.Debug($"Video download progress: {statusText}");
93
0 commit comments