| Conditions | 4 |
| Paths | 2 |
| Total Lines | 9 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 19 | public function authorize(): bool |
||
| 20 | { |
||
| 21 | if (($user = $this->user() ?: $this->attemptUser()) && $user->email_verified) { |
||
|
|
|||
| 22 | // Redirect users if their email already verified, no need to process their request |
||
| 23 | throw new GenericException(trans('cortex/fort::messages.verification.email.already_verified'), route('frontarea.account.settings')); |
||
| 24 | } |
||
| 25 | |||
| 26 | return true; |
||
| 27 | } |
||
| 28 | |||
| 39 |
If you implement
__calland you know which methods are available, you can improve IDE auto-completion and static analysis by adding a @method annotation to the class.This is often the case, when
__callis implemented by a parent class and only the child class knows which methods exist: