LogUpdatedCustomerEquipment   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Importance

Changes 0
Metric Value
wmc 1
eloc 5
c 0
b 0
f 0
dl 0
loc 11
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A handle() 0 6 1
1
<?php
2
3
namespace App\Listeners\Customers\Equipment;
4
5
use Illuminate\Support\Facades\Log;
6
use Illuminate\Support\Facades\Auth;
7
use App\Events\Customers\Equipment\CustomerEquipmentUpdatedEvent;
8
9
class LogUpdatedCustomerEquipment
10
{
11
    /**
12
     * Handle the event
13
     */
14
    public function handle(CustomerEquipmentUpdatedEvent $event)
15
    {
16
        Log::channel('cust')->info('Equipment has been updated for '.$event->cust->name.' by '.Auth::user()->username.'.  Details - ', [
17
            'cust_id'               => $event->cust->cust_id,
18
            'equipment'             => $event->equip->name,
19
            'equipment category id' => $event->equip->cat_id,
20
        ]);
21
    }
22
}
23