File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -80,7 +80,7 @@ public void MapRoutes(IEndpointRouteBuilder endpoints)
8080 endpoints . MapGet ( "/api/todos" , GetAll ) ;
8181 endpoints . MapGet ( "/api/todos/{id}" , Get ) ;
8282 endpoints . MapPost ( "/api/todos" , Post ) ;
83- endpoints . MapPost ( "/api/todos/{id}" , Delete ) ;
83+ endpoints . MapDelete ( "/api/todos/{id}" , Delete ) ;
8484 }
8585 }
8686}
Original file line number Diff line number Diff line change @@ -78,7 +78,7 @@ public void MapRoutes(IEndpointRouteBuilder endpoints)
7878 endpoints . MapGet ( "/api/todos" , WithDbContext ( GetAll ) ) ;
7979 endpoints . MapGet ( "/api/todos/{id}" , WithDbContext ( Get ) ) ;
8080 endpoints . MapPost ( "/api/todos" , WithDbContext ( Post ) ) ;
81- endpoints . MapPost ( "/api/todos/{id}" , WithDbContext ( Delete ) ) ;
81+ endpoints . MapDelete ( "/api/todos/{id}" , WithDbContext ( Delete ) ) ;
8282 }
8383
8484 private RequestDelegate WithDbContext ( Func < TodoDbContext , HttpContext , Task > handler )
You can’t perform that action at this time.
0 commit comments