Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 3fc0719

Browse filesBrowse files
Rick-Andersoncommonsensesoftware
authored andcommitted
use IsDevelopment
1 parent 99e527f commit 3fc0719
Copy full SHA for 3fc0719

File tree

Expand file treeCollapse file tree

2 files changed

+23
-23
lines changed
Filter options
Expand file treeCollapse file tree

2 files changed

+23
-23
lines changed

‎examples/AspNetCore/OData/SomeODataOpenApiExample/Program.cs

Copy file name to clipboardExpand all lines: examples/AspNetCore/OData/SomeODataOpenApiExample/Program.cs
+11-11Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -68,17 +68,17 @@
6868
{
6969
app.UseSwaggerUI(
7070
options =>
71-
{
72-
var descriptions = app.DescribeApiVersions();
73-
74-
// build a swagger endpoint for each discovered API version
75-
foreach ( var description in descriptions )
76-
{
77-
var url = $"/swagger/{description.GroupName}/swagger.json";
78-
var name = description.GroupName.ToUpperInvariant();
79-
options.SwaggerEndpoint( url, name );
80-
}
81-
} );
71+
{
72+
var descriptions = app.DescribeApiVersions();
73+
74+
// build a swagger endpoint for each discovered API version
75+
foreach ( var description in descriptions )
76+
{
77+
var url = $"/swagger/{description.GroupName}/swagger.json";
78+
var name = description.GroupName.ToUpperInvariant();
79+
options.SwaggerEndpoint( url, name );
80+
}
81+
} );
8282
}
8383
app.UseHttpsRedirection();
8484
app.UseAuthorization();

‎examples/AspNetCore/WebApi/OpenApiExample/Program.cs

Copy file name to clipboardExpand all lines: examples/AspNetCore/WebApi/OpenApiExample/Program.cs
+12-12Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -60,18 +60,18 @@
6060
if ( app.Environment.IsDevelopment() )
6161
{
6262
app.UseSwaggerUI(
63-
options =>
64-
{
65-
var descriptions = app.DescribeApiVersions();
66-
67-
// build a swagger endpoint for each discovered API version
68-
foreach ( var description in descriptions )
69-
{
70-
var url = $"/swagger/{description.GroupName}/swagger.json";
71-
var name = description.GroupName.ToUpperInvariant();
72-
options.SwaggerEndpoint( url, name );
73-
}
74-
} );
63+
options =>
64+
{
65+
var descriptions = app.DescribeApiVersions();
66+
67+
// build a swagger endpoint for each discovered API version
68+
foreach ( var description in descriptions )
69+
{
70+
var url = $"/swagger/{description.GroupName}/swagger.json";
71+
var name = description.GroupName.ToUpperInvariant();
72+
options.SwaggerEndpoint( url, name );
73+
}
74+
} );
7575
}
7676

7777
app.UseHttpsRedirection();

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.