diff --git a/src/MaaWpfGui/Models/ResourceUpdater.cs b/src/MaaWpfGui/Models/ResourceUpdater.cs index 9e9b8c3e3c..0efad40164 100644 --- a/src/MaaWpfGui/Models/ResourceUpdater.cs +++ b/src/MaaWpfGui/Models/ResourceUpdater.cs @@ -24,12 +24,15 @@ using MaaWpfGui.Constants; using MaaWpfGui.Helper; using MaaWpfGui.Main; using MaaWpfGui.ViewModels; +using Serilog; using Stylet; namespace MaaWpfGui.Models { public static class ResourceUpdater { + private static readonly ILogger _logger = Log.ForContext("SourceContext", "ResourceUpdater"); + private const string MaaResourceVersion = "resource/version.json"; private const string VersionChecksTemp = MaaResourceVersion + ".checks.tmp"; @@ -371,6 +374,11 @@ namespace MaaWpfGui.Models } while (retryCount++ < maxRetryTime); + if (updateResult == UpdateResult.Failed) + { + _logger.Warning($"Failed to get file, url: {url}, saveTo: {saveTo}"); + } + return updateResult; }