From d76c180c9631df015d37138045c79a46cca350e8 Mon Sep 17 00:00:00 2001 From: ivarlovlie Date: Fri, 28 Oct 2022 13:07:12 +0800 Subject: refactor: Add VaultService as a Singleton --- code/api/src/Program.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'code/api') diff --git a/code/api/src/Program.cs b/code/api/src/Program.cs index d670099..ebd686f 100644 --- a/code/api/src/Program.cs +++ b/code/api/src/Program.cs @@ -54,7 +54,7 @@ public static class Program builder.Services.AddScoped(); builder.Services.AddScoped(); builder.Services.AddScoped(); - builder.Services.AddTransient(); + builder.Services.AddSingleton(); var vaultService = builder.Services.BuildServiceProvider().GetRequiredService(); var configuration = vaultService.GetCurrentAppConfiguration(); var logger = new LoggerConfiguration() -- cgit v1.3