Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/duplicati/duplicati.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKaren Martikyan <kamartikyan@gmail.com>2020-11-08 23:16:00 +0300
committerKaren Martikyan <kamartikyan@gmail.com>2020-11-08 23:16:00 +0300
commit1feb75002d355b5dad5409e3e753b2c67033dc85 (patch)
treefe36312ea9428d99fe0d4ab11b2b759316fa9aca /Duplicati/Library
parente1b2a190ad4e530e9dee5ad187480607187a11e8 (diff)
Fixed bug connected with finding minimal element in an empty list
Diffstat (limited to 'Duplicati/Library')
-rw-r--r--Duplicati/Library/Backend/Telegram/TelegramBackend.cs5
1 files changed, 5 insertions, 0 deletions
diff --git a/Duplicati/Library/Backend/Telegram/TelegramBackend.cs b/Duplicati/Library/Backend/Telegram/TelegramBackend.cs
index 77cb021d7..4d151efb2 100644
--- a/Duplicati/Library/Backend/Telegram/TelegramBackend.cs
+++ b/Duplicati/Library/Backend/Telegram/TelegramBackend.cs
@@ -253,6 +253,11 @@ namespace Duplicati.Library.Backend
{
oldMinDate = newMinDate ?? 0;
RetrieveMessages(inputPeerChannel, result, oldMinDate);
+ if (result.Any() == false)
+ {
+ break;
+ }
+
newMinDate = result.Min(cfi => (int)cfi.Date.GetEpochSeconds());
}