Passed
Push — master ( 6758f1...14e78e )
by Curtis
05:20
created

FamilyEvent::boot()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 5
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 2
c 1
b 0
f 0
dl 0
loc 5
rs 10
cc 1
nc 1
nop 0
1
<?php
2
3
namespace App;
4
5
6
use Asdfx\LaravelGedcom\Observers\EventActionsObserver;
0 ignored issues
show
Bug introduced by
The type Asdfx\LaravelGedcom\Observers\EventActionsObserver 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...
7
use Illuminate\Database\Eloquent\SoftDeletes;
8
9
class FamilyEvent extends Event
10
{
11
    use SoftDeletes;
12
13
    /**
14
     * The attributes that should be mutated to dates.
15
     *
16
     * @var array
17
     */
18
    protected $dates = ['deleted_at'];
19
20
    protected $table    = 'family_events';
21
22
    protected $fillable = [
23
        'family_id',
24
        'places_id',
25
        'date',
26
        'title',
27
        'description',
28
        'year',
29
        'month',
30
        'day'
31
    ];
32
33
34
    public static function boot()
35
    {
36
        parent::boot();
37
38
        FamilyEvent::observe(new EventActionsObserver());
39
    }
40
41
    public function family()
42
    {
43
        return $this->hasOne(Family::class, 'id', 'family_id');
44
    }
45
}
46