Example #1
0
 public static async Task Initialize(ApplicationDbContext context, IConfiguration conf)
 {
     if (conf["SeedForce"].ToLower() == "true" ||
         !(context.GetService <IDatabaseCreator>() as RelationalDatabaseCreator)
         .Exists())
     {
         using (context)
             await CreateFirstUser(context);
     }
 }