From dae21743799f478de6c7d15de8ca5de916034658 Mon Sep 17 00:00:00 2001 From: Jonathan Gilbert Date: Tue, 10 Sep 2024 06:11:22 -0500 Subject: [PATCH] Updated the protected Storage constructor in Storage.cs to coalesce the supplied logger value to NullLoggerFactory.Instance, so that if a caller constructs an instance of BackblazeClient using the default logger value (which is null) then it still works. --- src/Client/Client/Storage/Storage.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Client/Client/Storage/Storage.cs b/src/Client/Client/Storage/Storage.cs index 25a25ac..d70d3d1 100644 --- a/src/Client/Client/Storage/Storage.cs +++ b/src/Client/Client/Storage/Storage.cs @@ -28,6 +28,8 @@ protected Storage(HttpClient client, IClientOptions options, ILoggerFactory logg try { // Initialize components + logger ??= NullLoggerFactory.Instance; + _client = new ApiClient(client, options, logger.CreateLogger(), cache); _logger = logger.CreateLogger(); }