diff --git a/DDNSUpdater/Logging/SpecterConsoleLoggerConfiguration.cs b/DDNSUpdater/Logging/SpecterConsoleLoggerConfiguration.cs index f77592f..8a544e2 100644 --- a/DDNSUpdater/Logging/SpecterConsoleLoggerConfiguration.cs +++ b/DDNSUpdater/Logging/SpecterConsoleLoggerConfiguration.cs @@ -8,6 +8,6 @@ public sealed class SpecterConsoleLoggerConfiguration public Dictionary LogLevelToColorMap { get; set; } = new() { - [LogLevel.Information] = ConsoleColor.Green + /*[LogLevel.Information] = ConsoleColor.Green*/ }; } \ No newline at end of file diff --git a/DDNSUpdater/Services/DDNSService.cs b/DDNSUpdater/Services/DDNSService.cs index b90142b..e3e6b04 100644 --- a/DDNSUpdater/Services/DDNSService.cs +++ b/DDNSUpdater/Services/DDNSService.cs @@ -16,7 +16,7 @@ namespace DDNSUpdater.Services; public class DDNSService : IDDNSService { - private List UpdateURLs { get; set; } + private List? UpdateURLs { get; set; } public List Domains { get; set; } private readonly ILogger _logger; @@ -45,7 +45,11 @@ public class DDNSService : IDDNSService public async void Start() { _logger.LogInformation("Fetching UpdateURLs"); - UpdateURLs = await GetUpdateURLs(); + while (UpdateURLs == null || UpdateURLs.Count == 0 ) + { + UpdateURLs = await GetUpdateURLs(); + } + _logger.LogInformation($"Fetched {UpdateURLs.Count} UpdateURLs"); }