-
Notifications
You must be signed in to change notification settings - Fork 554
/
ForgotPasswordController.php
51 lines (43 loc) · 1.41 KB
/
ForgotPasswordController.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<?php
namespace A17\Twill\Http\Controllers\Admin;
use Illuminate\Auth\Passwords\PasswordBrokerManager;
use Illuminate\Foundation\Auth\SendsPasswordResetEmails;
use Illuminate\View\Factory as ViewFactory;
class ForgotPasswordController extends Controller
{
/*
|--------------------------------------------------------------------------
| Password Reset Controller
|--------------------------------------------------------------------------
|
| This controller is responsible for handling password reset emails and
| includes a trait which assists in sending these notifications from
| your application to your users. Feel free to explore this trait.
|
*/
use SendsPasswordResetEmails;
/**
* @var PasswordBrokerManager
*/
protected $passwordBrokerManager;
public function __construct(PasswordBrokerManager $passwordBrokerManager)
{
parent::__construct();
$this->passwordBrokerManager = $passwordBrokerManager;
$this->middleware('twill_guest');
}
/**
* @return \Illuminate\Contracts\Auth\PasswordBroker
*/
public function broker()
{
return $this->passwordBrokerManager->broker('twill_users');
}
/**
* @return \Illuminate\Contracts\View\View
*/
public function showLinkRequestForm(ViewFactory $viewFactory)
{
return $viewFactory->make('twill::auth.passwords.email');
}
}