SendUnsubscribeNotification::handle()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 8

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 8
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
1
<?php
2
3
namespace Neo\EarlyAccess\Listeners;
4
5
use Neo\EarlyAccess\Events\UserUnsubscribed;
6
7
class SendUnsubscribeNotification
8
{
9
    /**
10
     * Handle the event.
11
     *
12
     * @param \Neo\EarlyAccess\Events\UserUnsubscribed $event
13
     * @return void
14
     */
15
    public function handle(UserUnsubscribed $event)
16
    {
17
        $notifierClass = config('early-access.notifications.unsubscribed');
18
19
        $event->subscriber->notify(
20
            new $notifierClass($event->subscriber)
21
        );
22
    }
23
}
24