public Auth0RedirectionMiddleware(RequestDelegate next, Auth0RedirectionMiddlewareOptions options, AuthDelegate authDelegate)
        {
            _next         = next;
            _authDelegate = authDelegate;

            if (options == null)
            {
                throw new Auth0RedirectionMiddlewareException("options parameter should not be null.");
            }

            _options = options;
        }
Exemple #2
0
 public static IApplicationBuilder UseAuth0RedirectionMiddlewareExtensions
     (this IApplicationBuilder builder, Auth0RedirectionMiddlewareOptions options, AuthDelegate authDelegate)
 {
     return(builder.UseMiddleware <Auth0RedirectionMiddleware>(options, authDelegate));
 }