From df6402644999bc23a639e809d9095f92de8d071b Mon Sep 17 00:00:00 2001 From: Matt Malec Date: Sun, 8 Nov 2020 21:57:22 -0500 Subject: [PATCH] Update AuthenticateIPAccess.php Fix a 500 error when processing a request with an IP filter --- app/Http/Middleware/Api/AuthenticateIPAccess.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Http/Middleware/Api/AuthenticateIPAccess.php b/app/Http/Middleware/Api/AuthenticateIPAccess.php index 30377794b..8f57b820d 100644 --- a/app/Http/Middleware/Api/AuthenticateIPAccess.php +++ b/app/Http/Middleware/Api/AuthenticateIPAccess.php @@ -29,7 +29,7 @@ class AuthenticateIPAccess } $find = new IP($request->ip()); - foreach (json_decode($model->allowed_ips) as $ip) { + foreach ($model->allowed_ips as $ip) { if (Range::parse($ip)->contains($find)) { return $next($request); }