Skip to content

Commit 326db93

Browse files
authored
[8.x] Fixes getting the trusted proxies IPs from the configuration file (#41322)
* Update TrustProxies.php * Use getter
1 parent 59d186c commit 326db93

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Illuminate/Http/Middleware/TrustProxies.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ public function handle(Request $request, Closure $next)
4747
*/
4848
protected function setTrustedProxyIpAddresses(Request $request)
4949
{
50-
$trustedIps = $this->proxies();
50+
$trustedIps = $this->proxies() ?: config('trustedproxy.proxies');
5151

5252
if ($trustedIps === '*' || $trustedIps === '**') {
5353
return $this->setTrustedProxyIpAddressesToTheCallingIp($request);

0 commit comments

Comments
 (0)