Completed
Push — master ( 943fe6...d5ae66 )
by archer
02:53
created

ApiAuthAccessEvent::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 2
dl 0
loc 5
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 1
1
<?php
2
3
4
namespace ArcherZdip\LaravelApiAuth\Models;
5
6
7
use Illuminate\Database\Eloquent\Model;
0 ignored issues
show
Bug introduced by
The type Illuminate\Database\Eloquent\Model was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
8
9
class ApiAuthAccessEvent extends Model
10
{
11
    /**
12
     * The attributes that are mass assignable.
13
     *
14
     * @var array
15
     */
16
    protected $fillable = [
17
        'appid',
18
        'ip_address',
19
        'url',
20
        'params',
21
        'type',
22
    ];
23
24
    /**
25
     * The attributes that should be hidden for arrays.
26
     *
27
     * @var array
28
     */
29
    protected $hidden = [];
30
31
    protected $casts = [
32
        'params' => 'array'
33
    ];
34
35
    /**
36
     * ApiAuthAccessEvent constructor.
37
     * @param array $attributes
38
     */
39
    public function __construct(array $attributes = [])
40
    {
41
        parent::__construct($attributes);
42
43
        $this->setTable(config('apikey.table_name.api_auth_access_events'));
0 ignored issues
show
Bug introduced by
The function config was not found. Maybe you did not declare it correctly or list all dependencies? ( Ignorable by Annotation )

If this is a false-positive, you can also ignore this issue in your code via the ignore-call  annotation

43
        $this->setTable(/** @scrutinizer ignore-call */ config('apikey.table_name.api_auth_access_events'));
Loading history...
44
    }
45
}