diff options
| author | Jim Cartlidge <jimcartlidge@yahoo.co.uk> | 2020-09-12 17:21:03 +0100 |
|---|---|---|
| committer | Jim Cartlidge <jimcartlidge@yahoo.co.uk> | 2020-09-12 17:21:03 +0100 |
| commit | 288d89493e76b8881c719fe549859b2c0b5f7e29 (patch) | |
| tree | b5cbb9d5216f805acbe8f167b8dbefd77982a5d2 /Jellyfin.Server/Middleware/IpBasedAccessValidationMiddleware.cs | |
| parent | 9ef79d190b2490a03c566bfaaf963fbba7d124a9 (diff) | |
Fixed testing units.
Diffstat (limited to 'Jellyfin.Server/Middleware/IpBasedAccessValidationMiddleware.cs')
| -rw-r--r-- | Jellyfin.Server/Middleware/IpBasedAccessValidationMiddleware.cs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Jellyfin.Server/Middleware/IpBasedAccessValidationMiddleware.cs b/Jellyfin.Server/Middleware/IpBasedAccessValidationMiddleware.cs index 110290027..ff82fe6cc 100644 --- a/Jellyfin.Server/Middleware/IpBasedAccessValidationMiddleware.cs +++ b/Jellyfin.Server/Middleware/IpBasedAccessValidationMiddleware.cs @@ -34,8 +34,9 @@ namespace Jellyfin.Server.Middleware /// <returns>The async task.</returns> public async Task Invoke(HttpContext httpContext, INetworkManager networkManager, IServerConfigurationManager serverConfigurationManager) { - if (httpContext.IsLocal()) + if (httpContext.Connection.RemoteIpAddress == null) { + // Running locally. await _next(httpContext).ConfigureAwait(false); return; } |
