EventServiceProvider   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 30
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 1
dl 0
loc 30
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A boot() 0 6 1
1
<?php
2
3
namespace App\Providers;
4
5
use App\Events\PostWasViewed;
6
use App\Events\UserCreationRequestSent;
7
use App\Listeners\SendConfirmationCode;
8
use App\Listeners\ViewPostHandler;
9
use Illuminate\Contracts\Events\Dispatcher as DispatcherContract;
10
use Illuminate\Foundation\Support\Providers\EventServiceProvider as ServiceProvider;
11
12
class EventServiceProvider extends ServiceProvider
13
{
14
    /**
15
     * The event listener mappings for the application.
16
     *
17
     * @var array
18
     */
19
    protected $listen = [
20
        PostWasViewed::class => [
21
            ViewPostHandler::class
22
        ],
23
        
24
        UserCreationRequestSent::class => [
25
            SendConfirmationCode::class
26
        ]
27
    ];
28
29
    /**
30
     * Register any other events for your application.
31
     *
32
     * @param  \Illuminate\Contracts\Events\Dispatcher  $events
33
     * @return void
34
     */
35
    public function boot(DispatcherContract $events)
36
    {
37
        parent::boot($events);
38
39
        //
40
    }
41
}
42