GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

HomeController::__construct()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 3
nc 1
nop 1
dl 0
loc 5
rs 9.4285
c 0
b 0
f 0
1
<?php
2
3
namespace App\Http\Controllers;
4
5
use App\Models\Transaction;
6
use App\Services\TransactionService;
7
use Auth;
8
9
class HomeController extends Controller
10
{
11
    /**
12
     * @var TransactionService
13
     */
14
    private $transactionService;
15
16
    /**
17
     * Create a new controller instance.
18
     *
19
     * @param TransactionService $transactionService
20
     */
21
    public function __construct(TransactionService $transactionService)
22
    {
23
        $this->middleware('auth');
24
        $this->transactionService = $transactionService;
25
    }
26
27
    /**
28
     * Show the application dashboard.
29
     *
30
     * @return \Illuminate\Http\Response
31
     */
32
    public function index($id = null)
33
    {
34
        $transaction = null;
35
        if ($id) {
36
            $transaction = $this->transactionService->getTransaction(Auth::user(), $id);
37
        }
38
39
        return view('home', compact('transaction'));
40
    }
41
}
42