Startup typeof error edited

This commit is contained in:
Onurkan Bakırcı 2022-03-21 15:44:40 +03:00 committed by GitHub
parent 7c6221cc22
commit a04a00241b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 5 additions and 5 deletions

View File

@ -30,7 +30,7 @@ public class Startup
services.AddSwaggerGen(options =>
{
var basePath = AppDomain.CurrentDomain.BaseDirectory;
var fileName = typeof(Program).GetTypeInfo().Assembly.GetName().Name + ".xml";
var fileName = typeof(Startup).GetTypeInfo().Assembly.GetName().Name + ".xml";
var xmlComments = Path.Combine(basePath, fileName);
options.IncludeXmlComments(xmlComments);
options.SwaggerDoc("v1", new OpenApiInfo

View File

@ -223,7 +223,7 @@ public static class CustomExtensionMethods
services.AddSwaggerGen(options =>
{
var basePath = AppDomain.CurrentDomain.BaseDirectory;
var fileName = typeof(Program).GetTypeInfo().Assembly.GetName().Name + ".xml";
var fileName = typeof(Startup).GetTypeInfo().Assembly.GetName().Name + ".xml";
var xmlComments = Path.Combine(basePath, fileName);
options.IncludeXmlComments(xmlComments);
options.SwaggerDoc("v1", new OpenApiInfo

View File

@ -90,7 +90,7 @@ namespace Microsoft.eShopOnContainers.Services.Identity.API
services.AddRazorPages();
var basePath = AppDomain.CurrentDomain.BaseDirectory;
var fileName = typeof(Program).GetTypeInfo().Assembly.GetName().Name + ".xml";
var fileName = typeof(Startup).GetTypeInfo().Assembly.GetName().Name + ".xml";
var xmlComments = Path.Combine(basePath, fileName);
options.IncludeXmlComments(xmlComments);
options.SwaggerDoc("v1", new OpenApiInfo

View File

@ -216,7 +216,7 @@ static class CustomExtensionsMethods
services.AddSwaggerGen(options =>
{
var basePath = AppDomain.CurrentDomain.BaseDirectory;
var fileName = typeof(Program).GetTypeInfo().Assembly.GetName().Name + ".xml";
var fileName = typeof(Startup).GetTypeInfo().Assembly.GetName().Name + ".xml";
var xmlComments = Path.Combine(basePath, fileName);
options.IncludeXmlComments(xmlComments);
options.SwaggerDoc("v1", new OpenApiInfo

View File

@ -140,7 +140,7 @@ static class CustomExtensionMethods
services.AddSwaggerGen(options =>
{
var basePath = AppDomain.CurrentDomain.BaseDirectory;
var fileName = typeof(Program).GetTypeInfo().Assembly.GetName().Name + ".xml";
var fileName = typeof(Startup).GetTypeInfo().Assembly.GetName().Name + ".xml";
var xmlComments = Path.Combine(basePath, fileName);
options.IncludeXmlComments(xmlComments);
options.SwaggerDoc("v1", new OpenApiInfo