Merge pull request #145 from dotnet/Rick-Anderson-patch-1

Update Program.cs
pull/146/head
Rick Anderson 2023-05-17 15:18:03 -10:00 committed by GitHub
commit 857f42a947
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 0 additions and 4 deletions

View File

@ -321,14 +321,10 @@ app.Run();
// <snippet_sampleproblemdetailswriter>
var builder = WebApplication.CreateBuilder(args);
// Add services to the container.
// addd SampleProblemDetailsWriter to dependency injection
builder.Services.AddTransient<IProblemDetailsWriter, SampleProblemDetailsWriter>();
var app = builder.Build();
// Middleware to handle writing problem details to the response.
app.Use(async (context, next) =>
{