mirror of
https://github.com/codeigniter4/CodeIgniter4.git
synced 2025-02-20 11:44:28 +08:00
remove unnecessary foreach in RouteCollection::checkSubdomains()
This commit is contained in:
parent
d027176440
commit
804f8497fa
@ -1517,15 +1517,7 @@ class RouteCollection implements RouteCollectionInterface
|
||||
return true;
|
||||
}
|
||||
|
||||
foreach ($subdomains as $subdomain)
|
||||
{
|
||||
if ($subdomain === $this->currentSubdomain)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
return in_array($this->currentSubdomain, $subdomains, true);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------
|
||||
|
Loading…
x
Reference in New Issue
Block a user