public void Configure(IApplicationBuilder app , IHostingEnvironment env , JwtIdentityContext context , UserManager <IdentityUser> userManager) { if (env.IsDevelopment()) { app.UseDeveloperExceptionPage(); } app.UseCors(option => option.AllowAnyOrigin() .AllowAnyHeader() .AllowCredentials());; app.UseAuthentication(); app.UseMvc(); new InitializeDB(context, userManager).Init(); }
public InitializeDB(JwtIdentityContext context , UserManager <IdentityUser> userManager) { _context = context; _userManager = userManager; }