LaravelOverflow   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 1
dl 0
loc 16
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 6 1
1
<?php
2
3
namespace CraftLogan\LaravelOverflow;
4
5
use Illuminate\Database\Eloquent\Model;
6
use Illuminate\Http\Request;
7
use CraftLogan\LaravelOverflow\Overflowable;
8
9
class LaravelOverflow
10
{
11
    use Overflowable;
12
13
    protected $model;
14
    protected $overflow_column;
15
    protected $request;
16
17
    public function __construct(Request $request, Model $model, $overflow_column = "properties")
0 ignored issues
show
Bug introduced by
You have injected the Request via parameter $request. This is generally not recommended as there might be multiple instances during a request cycle (f.e. when using sub-requests). Instead, it is recommended to inject the RequestStack and retrieve the current request each time you need it via getCurrentRequest().
Loading history...
18
    {
19
        $this->request = $request;
20
        $this->model = $model;
21
        $this->overflow_column = $overflow_column;
22
    }
23
24
}
25