We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents c7c1f7f + 084ea13 commit 9fff194Copy full SHA for 9fff194
src/Traits/RegistersUsers.php
@@ -43,9 +43,8 @@ public function register(Request $request)
43
*/
44
public function confirm($id, $confirmation_code)
45
{
46
- $model = config('auth.providers.users.model');
47
-
48
- $user = $model::whereId($id)->whereConfirmationCode($confirmation_code)->firstOrFail();
+ $model = $this->guard()->getProvider()->createModel();
+ $user = $model->whereId($id)->whereConfirmationCode($confirmation_code)->firstOrFail();
49
$user->confirmation_code = null;
50
$user->confirmed = true;
51
$user->save();
0 commit comments