aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/auth/auth.php
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/includes/auth/auth.php')
-rw-r--r--phpBB/includes/auth/auth.php7
1 files changed, 3 insertions, 4 deletions
diff --git a/phpBB/includes/auth/auth.php b/phpBB/includes/auth/auth.php
index ab84619977..279959974d 100644
--- a/phpBB/includes/auth/auth.php
+++ b/phpBB/includes/auth/auth.php
@@ -927,14 +927,13 @@ class phpbb_auth
*/
function login($username, $password, $autologin = false, $viewonline = 1, $admin = 0)
{
- global $config, $db, $user, $phpbb_root_path, $phpEx;
+ global $config, $db, $user, $phpbb_root_path, $phpEx, $phpbb_container;
$method = trim(basename($config['auth_method']));
- $class = 'phpbb_auth_provider_' . $method;
- if (class_exists($class))
+ $provider = $phpbb_container->get('auth.provider.' . $method);
+ if ($provider)
{
- $provider = new $class();
$login = $provider->login($username, $password);
// If the auth module wants us to create an empty profile do so and then treat the status as LOGIN_SUCCESS