mirror of
https://github.com/collinbarrett/FilterLists.git
synced 2026-03-11 09:04:27 +00:00
parent
df8877207d
commit
ce3908c8c5
1 changed files with 8 additions and 9 deletions
|
|
@ -58,17 +58,16 @@ public void Configure(IApplicationBuilder app, IHostingEnvironment env)
|
|||
app.UseStaticFiles();
|
||||
app.UseCookiePolicy();
|
||||
app.UseMvc();
|
||||
app.UseSwagger(
|
||||
c =>
|
||||
{
|
||||
c.PreSerializeFilters.Add((swaggerDoc, httpReq) => swaggerDoc.Host = httpReq.Host.Value);
|
||||
UseLowercaseControllerNameInSwaggerHack(c);
|
||||
});
|
||||
|
||||
app.UseSwagger(c =>
|
||||
{
|
||||
c.RouteTemplate = "docs/{documentName}/swagger.json";
|
||||
c.PreSerializeFilters.Add((swaggerDoc, httpReq) => swaggerDoc.Host = httpReq.Host.Value);
|
||||
UseLowercaseControllerNameInSwaggerHack(c);
|
||||
});
|
||||
app.UseSwaggerUI(c =>
|
||||
{
|
||||
c.SwaggerEndpoint("/swagger/v1/swagger.json", "FilterLists API V1");
|
||||
c.DocumentTitle = "FilterLists API";
|
||||
c.SwaggerEndpoint("/docs/v1/swagger.json", "FilterLists API v1");
|
||||
c.DocumentTitle = "FilterLists API v1";
|
||||
c.RoutePrefix = "docs";
|
||||
});
|
||||
MigrateAndSeedDatabase(app);
|
||||
|
|
|
|||
Loading…
Reference in a new issue