laravel / fortify

Backend controllers and scaffolding for Laravel authentication.

Home Page:https://laravel.com/docs/fortify

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support for only one a user provider in an action

martio opened this issue · comments

  • Fortify Version: 1.11.2
  • Laravel Version: 9.9.0
  • PHP Version: 8.1.3
  • Database Driver & Version: MySQL 8

Description:

In the Laravel\Fortify\Actions\RedirectIfTwoFactorAuthenticatable class, we use a user provider, but assume it's only EloquentUserProvider. This does not work with the DatabaseUserProvider or custom provider.

Steps To Reproduce:

Set in the config/auth.php file:

    'providers' => [
        'users' => [
            'driver' => 'database',
            'table' => 'users',
        ],
    ],

It's only intended to use with Eloquent.