Completed
Push — master ( 2b6acf...5f05b1 )
by Christopher
03:20
created

Comment::commentable()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 4
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
namespace Chriscreate\Blog;
4
5
use Chriscreate\Blog\Traits\Comment\CommentApproval;
6
use Chriscreate\Blog\Traits\Comment\CommentScopes;
7
use Chriscreate\Blog\Traits\IsAuthorable;
8
use Illuminate\Database\Eloquent\Model;
9
10
class Comment extends Model
11
{
12
    use CommentScopes,
13
    CommentApproval,
14
    IsAuthorable;
15
16
    protected $table = 'comments';
17
18
    protected $primaryKey = 'id';
19
20
    public $guarded = [];
21
22
    public $timestamps = true;
23
24
    public function commentable()
25
    {
26
        return $this->morphTo();
27
    }
28
}
29