Table of Contents

Class FallbackMiddleware

Namespace
DuetWebServer.Middleware
Assembly
DuetWebServer.dll

Middleware class to redirect GET requests without dot in the path to the main index file

public class FallbackMiddleware
Inheritance
FallbackMiddleware
Inherited Members

Constructors

FallbackMiddleware(RequestDelegate, ILogger<FallbackMiddleware>)

Middleware class to redirect GET requests without dot in the path to the main index file

public FallbackMiddleware(RequestDelegate next, ILogger<FallbackMiddleware> logger)

Parameters

next RequestDelegate

Next request delegate

logger ILogger<FallbackMiddleware>

Logger instance

Methods

InvokeAsync(HttpContext)

Method that is invoked when a new request is coming in. Redirects pages that could not be found to the index page

public Task InvokeAsync(HttpContext context)

Parameters

context HttpContext

HTTP context

Returns

Task

Asynchronous task