Fix compilation error: Add using statement for HttpOverrides
This commit is contained in:
parent
2a9039bd7a
commit
2fb173696e
@ -1,5 +1,6 @@
|
|||||||
using Microsoft.EntityFrameworkCore;
|
using Microsoft.EntityFrameworkCore;
|
||||||
using Microsoft.AspNetCore.Authentication.JwtBearer;
|
using Microsoft.AspNetCore.Authentication.JwtBearer;
|
||||||
|
using Microsoft.AspNetCore.HttpOverrides;
|
||||||
using Microsoft.IdentityModel.Tokens;
|
using Microsoft.IdentityModel.Tokens;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using LittleShop.Data;
|
using LittleShop.Data;
|
||||||
@ -229,10 +230,9 @@ catch (Exception ex)
|
|||||||
// Configure the HTTP request pipeline.
|
// Configure the HTTP request pipeline.
|
||||||
|
|
||||||
// Configure forwarded headers for proxy scenarios (nginx, etc)
|
// Configure forwarded headers for proxy scenarios (nginx, etc)
|
||||||
var forwardedHeadersOptions = new Microsoft.AspNetCore.HttpOverrides.ForwardedHeadersOptions
|
var forwardedHeadersOptions = new ForwardedHeadersOptions
|
||||||
{
|
{
|
||||||
ForwardedHeaders = Microsoft.AspNetCore.HttpOverrides.ForwardedHeaders.XForwardedFor |
|
ForwardedHeaders = ForwardedHeaders.XForwardedFor | ForwardedHeaders.XForwardedProto
|
||||||
Microsoft.AspNetCore.HttpOverrides.ForwardedHeaders.XForwardedProto
|
|
||||||
};
|
};
|
||||||
// Clear the default known networks/proxies to allow any proxy
|
// Clear the default known networks/proxies to allow any proxy
|
||||||
forwardedHeadersOptions.KnownNetworks.Clear();
|
forwardedHeadersOptions.KnownNetworks.Clear();
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user