Comment   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 17
Duplicated Lines 0 %

Importance

Changes 2
Bugs 0 Features 0
Metric Value
wmc 3
eloc 5
c 2
b 0
f 0
dl 0
loc 17
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A commentable() 0 3 1
A creatable() 0 3 1
A getCommentAttribute() 0 3 1
1
<?php
2
3
namespace FaithGen\SDK\Models;
4
5
class Comment extends UuidModel
6
{
7
    protected $table = 'fg_comments';
8
9
    public function commentable()
10
    {
11
        return $this->morphTo();
12
    }
13
14
    public function creatable()
15
    {
16
        return $this->morphTo();
17
    }
18
19
    public function getCommentAttribute($val)
20
    {
21
        return ucfirst($val);
22
    }
23
}
24