mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-11 22:08:54 +00:00
[feature/avatars] Use isset() instead of in_array()
PHPBB3-10018
This commit is contained in:
parent
8c782122c1
commit
01b313ea26
1 changed files with 2 additions and 2 deletions
|
@ -79,7 +79,7 @@ class phpbb_avatar_manager
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!in_array($avatar_type, self::$valid_drivers))
|
if (!isset(self::$valid_drivers[$avatar_type]))
|
||||||
{
|
{
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
@ -109,7 +109,7 @@ class phpbb_avatar_manager
|
||||||
self::$valid_drivers = array();
|
self::$valid_drivers = array();
|
||||||
foreach ($this->avatar_drivers as $driver)
|
foreach ($this->avatar_drivers as $driver)
|
||||||
{
|
{
|
||||||
self::$valid_drivers[] = $driver->get_name();
|
self::$valid_drivers[$driver->get_name()] = $driver->get_name();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue