1 write to _options
Microsoft.AspNetCore.Diagnostics (1)
ExceptionHandler\ExceptionHandlerMiddlewareImpl.cs (1)
43_options = options.Value;
12 references to _options
Microsoft.AspNetCore.Diagnostics (12)
ExceptionHandler\ExceptionHandlerMiddlewareImpl.cs (12)
51if (_options.ExceptionHandler == null) 53if (_options.ExceptionHandlingPath == null) 62_options.ExceptionHandler = _next; 142if (_options.ExceptionHandlingPath.HasValue) 144context.Request.Path = _options.ExceptionHandlingPath; 146var oldScope = _options.CreateScopeForErrors ? context.RequestServices : null; 147await using AsyncServiceScope? scope = _options.CreateScopeForErrors ? context.RequestServices.GetRequiredService<IServiceScopeFactory>().CreateAsyncScope() : null; 168context.Response.StatusCode = _options.StatusCodeSelector?.Invoke(edi.SourceException) ?? DefaultStatusCode; 185if (_options.ExceptionHandler is not null) 187await _options.ExceptionHandler!(context); 205if (context.Response.HasStarted || handled || _options.StatusCodeSelector != null || context.Response.StatusCode != StatusCodes.Status404NotFound || _options.AllowStatusCode404Response)