try ugly fix to Swagger endpoint to support debug and release

ref #131
This commit is contained in:
Collin Barrett 2018-06-06 19:09:41 -05:00
parent 5f73d1eed7
commit 9c0f32fce6

View file

@ -57,7 +57,11 @@ public void Configure(IApplicationBuilder app, IHostingEnvironment env)
app.UseSwagger(UseLowercaseControllerNameInSwaggerHack);
app.UseSwaggerUI(c =>
{
#if DEBUG
c.SwaggerEndpoint("/swagger/v1/swagger.json", "FilterLists API V1");
#else
c.SwaggerEndpoint("/api/swagger/v1/swagger.json", "FilterLists API V1");
#endif
c.RoutePrefix = "docs";
});
app.UseHttpsRedirection();