mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-10 21:38:54 +00:00
[ticket/16799] Use offsetExists() method instead of array_key_exists()
PHPBB3-16799
This commit is contained in:
parent
7b5ad8bb74
commit
dd62829f96
1 changed files with 2 additions and 2 deletions
|
@ -163,7 +163,7 @@ class oauth extends base
|
|||
$provider = $this->request->variable('oauth_service', '', false);
|
||||
$service_name = $this->get_service_name($provider);
|
||||
|
||||
if ($provider === '' || !array_key_exists($service_name, (array) $this->service_providers))
|
||||
if ($provider === '' || !$this->service_providers->offsetExists($service_name))
|
||||
{
|
||||
return [
|
||||
'status' => LOGIN_ERROR_EXTERNAL_AUTH,
|
||||
|
@ -452,7 +452,7 @@ class oauth extends base
|
|||
|
||||
$service_name = $this->get_service_name($link_data['oauth_service']);
|
||||
|
||||
if (!array_key_exists($service_name, (array) $this->service_providers))
|
||||
if (!$this->service_providers->offsetExists($service_name))
|
||||
{
|
||||
return 'LOGIN_ERROR_OAUTH_SERVICE_DOES_NOT_EXIST';
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue