Ejemplo n.º 1
0
 // This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
 public void Configure(IApplicationBuilder app,
                       IHostingEnvironment env,
                       ILoggerFactory loggerFactory,
                       CarUserInitializer seeder)
 {
     loggerFactory.AddConsole(_config.GetSection("Logging"));
     loggerFactory.AddDebug();
     app.UseIdentity();
     app.UseMvc();
     seeder.Seed().Wait();
 }
Ejemplo n.º 2
0
 // This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
 public void Configure(IApplicationBuilder app,
                       IHostingEnvironment env,
                       ILoggerFactory loggerFactory,
                       CarUserInitializer seeder)
 {
     if (env.IsDevelopment())
     {
         app.UseDeveloperExceptionPage();
     }
     else
     {
         app.UseHsts();
     }
     loggerFactory.AddConsole(_config.GetSection("Logging"));
     loggerFactory.AddDebug();
     app.UseIdentity();
     seeder.Seed().Wait();
     app.UseHttpsRedirection();
     app.UseMvc();
 }