Logout::handle()   A
last analyzed

Complexity

Conditions 2
Paths 2

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 3
Bugs 0 Features 0
Metric Value
cc 2
eloc 2
c 3
b 0
f 0
nc 2
nop 1
dl 0
loc 4
rs 10
1
<?php namespace GeneaLabs\LaravelMixpanel\Listeners;
2
3
use GeneaLabs\LaravelMixpanel\Events\MixpanelEvent as Mixpanel;
4
use Illuminate\Auth\Events\Logout as LogoutEvent;
5
6
class Logout
7
{
8
    public function handle(LogoutEvent $logout)
9
    {
10
        if (config("services.mixpanel.enable-default-tracking")) {
11
            event(new Mixpanel($logout->user, ['User Logged Out' => []]));
12
        }
13
    }
14
}
15