1 write to _options
Microsoft.AspNetCore.Diagnostics (1)
ExceptionHandler\ExceptionHandlerMiddlewareImpl.cs (1)
43_options = options.Value;
15 references to _options
Microsoft.AspNetCore.Diagnostics (15)
ExceptionHandler\ExceptionHandlerMiddlewareImpl.cs (15)
51if (_options.ExceptionHandler == null) 53if (_options.ExceptionHandlingPath == null) 62_options.ExceptionHandler = _next; 141if (_options.ExceptionHandlingPath.HasValue) 143context.Request.Path = _options.ExceptionHandlingPath; 145var oldScope = _options.CreateScopeForErrors ? context.RequestServices : null; 146await using AsyncServiceScope? scope = _options.CreateScopeForErrors ? context.RequestServices.GetRequiredService<IServiceScopeFactory>().CreateAsyncScope() : null; 169context.Response.StatusCode = _options.StatusCodeSelector?.Invoke(edi.SourceException) 191if (_options.ExceptionHandler is not null) 193await _options.ExceptionHandler!(context); 198if (_options.ExceptionHandlingPath.HasValue) 201handlerTag = _options.ExceptionHandlingPath.Value; 225if (result != ExceptionHandledType.Unhandled || _options.StatusCodeSelector is not null || is404FromBadHttpRequestException || context.Response.StatusCode != StatusCodes.Status404NotFound || _options.AllowStatusCode404Response) 232if (_options.SuppressDiagnosticsCallback is { } suppressCallback)