| 1 | <?php |
||
| 10 | class AuthServiceProvider extends ServiceProvider |
||
| 11 | { |
||
| 12 | /** |
||
| 13 | * The policy mappings for the application. |
||
| 14 | * |
||
| 15 | * @var array |
||
| 16 | */ |
||
| 17 | protected $policies = [ |
||
| 18 | User::class => UserPolicy::class, |
||
| 19 | ]; |
||
| 20 | |||
| 21 | /** |
||
| 22 | * Register any application authentication / authorization services. |
||
| 23 | * |
||
| 24 | * @param \Illuminate\Contracts\Auth\Access\Gate $gate |
||
| 25 | */ |
||
| 26 | public function boot(GateContract $gate) |
||
| 32 | } |
||
| 33 |
This check looks for a call to a parent method whose name is different than the method from which it is called.
Consider the following code:
The
getFirstName()method in theSoncalls the wrong method in the parent class.