Thomasvdw
1 month ago
819
11
Laravel

Unable to resolve NULL driver for [Illuminate\Mail\TransportManager]

Posted 1 month ago by Thomasvdw

Hi all,

I am stuck on "Unable to resolve NULL driver for [Illuminate\Mail\TransportManager]" in attempting to send e-mail verification e-mail on user registration using gmail.

in routes/web.php I have:

Auth::routes(['verify' => true]);

and app/user.php contains:

use Illuminate\Notifications\Notifiable;
use Illuminate\Contracts\Auth\MustVerifyEmail;
use Illuminate\Foundation\Auth\User as Authenticatable;

class User extends Authenticatable implements MustVerifyEmail

in .env:

MAIL_DRIVER=smtp
MAIL_HOST=smtp.googlemail.com
MAIL_PORT=465
MAIL_USERNAME=[username]@gmail.com
MAIL_PASSWORD=[password]
MAIL_ENCRYPTION=ssl

To make sure the .env is used by config/mail.php, I ran:

php artisan config:cache
php artisan config:clear
php artisan cache:clear

Subsequently, I see in tinker that env('MAIL_PASSWORD') returns the valid response (not-null).

Nonetheless, I keep getting this NULL driver error; what can I do?

Please sign in or create an account to participate in this conversation.