Skip to content

Commit 91b1974

Browse files
committed
improvement: minor changes
1 parent 2d8465e commit 91b1974

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

ProjectTemplates/AspNetCore.WebApi/ReferenceProject/ReferenceProject/Configuration/DependenciesConfig.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,10 @@ public static IServiceCollection AddSwagger(this IServiceCollection services)
1818
// Set the comments path for the Swagger JSON and UI.
1919
var xmlFile = $"{Assembly.GetExecutingAssembly().GetName().Name}.xml";
2020
var xmlPath = Path.Combine(AppContext.BaseDirectory, xmlFile);
21-
c.IncludeXmlComments(xmlPath);
21+
if (File.Exists(xmlPath))
22+
{
23+
c.IncludeXmlComments(xmlPath);
24+
}
2225
});
2326

2427
return services;

ProjectTemplates/AspNetCore.WebApi/ReferenceProject/ReferenceProject/Controllers/ProductsController.cs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@
99

1010
namespace ReferenceProject.Controllers
1111
{
12-
/// <summary>
13-
/// Products Controller
14-
/// </summary>
1512
[Route("[controller]")]
1613
[ApiController]
1714
[Produces("application/json")]

0 commit comments

Comments
 (0)