Remove unused middleware
This commit is contained in:
parent
444bc9d4bc
commit
bbf2e9cba7
1 changed files with 0 additions and 26 deletions
|
|
@ -1,26 +0,0 @@
|
|||
using LANCommander.Server.Services;
|
||||
|
||||
namespace LANCommander.Server
|
||||
{
|
||||
public class ApiMiddleware
|
||||
{
|
||||
private readonly RequestDelegate Next;
|
||||
|
||||
public ApiMiddleware(RequestDelegate next)
|
||||
{
|
||||
Next = next;
|
||||
}
|
||||
|
||||
public async Task InvokeAsync(HttpContext context)
|
||||
{
|
||||
context.Response.OnStarting(() =>
|
||||
{
|
||||
context.Response.Headers["X-API-Version"] = UpdateService.GetCurrentVersion().ToString();
|
||||
|
||||
return Task.CompletedTask;
|
||||
});
|
||||
|
||||
await Next(context);
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue