CommentType::comments()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 1
dl 0
loc 3
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
namespace App\Models\Lookup;
4
5
use Illuminate\Database\Eloquent\Model;
6
7
/**
8
 * Class CommentType
9
 *
10
 * @property int $id
11
 * @property string $name
12
 * @property \Jenssegers\Date\Date $created_at
13
 * @property \Jenssegers\Date\Date $updated_at
14
 *
15
 * @property \Illuminate\Database\Eloquent\Collection $comments
16
 */
17
18
class CommentType extends Model
19
{
20
    protected $fillable = [];
21
22
    public function comments() // phpcs:ignore
23
    {
24
        return $this->hasMany(\App\Models\Comment::class, 'type_id');
25
    }
26
}
27