Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
2 / 2
CRAP
100.00% covered (success)
100.00%
1 / 1
UpdateInstancyUser
100.00% covered (success)
100.00%
2 / 2
100.00% covered (success)
100.00%
2 / 2
2
100.00% covered (success)
100.00%
1 / 1
 __construct
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
 handle
100.00% covered (success)
100.00%
1 / 1
100.00% covered (success)
100.00%
1 / 1
1
1<?php
2
3namespace App\Listeners;
4
5use App\Events\InstancyUserUpdate;
6use App\Http\Repositories\InstancyRepository;
7use Illuminate\Contracts\Queue\ShouldQueue;
8
9class UpdateInstancyUser implements ShouldQueue
10{
11    protected $instancyRepository;
12
13    /**
14     * Create the event listener.
15     */
16    public function __construct(InstancyRepository $instancyRepository)
17    {
18        $this->instancyRepository = $instancyRepository;
19    }
20
21    /**
22     * Handle the event.
23     */
24    public function handle(InstancyUserUpdate $event)
25    {
26        $this->instancyRepository->updateUser($event->instancyUser);
27    }
28}