Quantcast
Channel: Login only if user is active using Laravel - Stack Overflow
Viewing all articles
Browse latest Browse all 25

Answer by albert for Login only if user is active using Laravel

$
0
0

On laravel 7, you only need to put this method on LoginController:

/** * Custom credentials to validate the status of user. */public function credentials(Request $request){    return ['email'     => $request->email,'password'  => $request->password,'is_active' => '1'    ];}

In this way, you can validate any condition for login.


Viewing all articles
Browse latest Browse all 25

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>