We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 703fd8a commit 908dbe7Copy full SHA for 908dbe7
1 file changed
EmailService-API/Program.cs
@@ -5,6 +5,7 @@
5
using Microsoft.AspNetCore.Authentication.JwtBearer;
6
using Microsoft.IdentityModel.Tokens;
7
using System.Text;
8
+using Microsoft.AspNetCore.DataProtection;
9
10
namespace EmailService_API
11
{
@@ -18,6 +19,9 @@ public static void Main(string[] args)
18
19
var connectionString = builder.Configuration.GetConnectionString("EmailServiceContextConnection");
20
builder.Services.AddDbContext<EmailServiceContext>(options =>
21
options.UseSqlServer(connectionString));
22
+
23
+ builder.Services.AddDataProtection()
24
+ .PersistKeysToDbContext<EmailServiceContext>();
25
26
builder.Services.AddControllers();
27
0 commit comments