Passed
Push — master ( 68443e...939347 )
by Mihail
04:31
created

FeedbackAnswer   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
c 1
b 0
f 0
lcom 1
cbo 1
dl 0
loc 11
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A getFeedbackPost() 0 4 1
1
<?php
2
3
namespace Apps\ActiveRecord;
4
5
6
use Ffcms\Core\Arch\ActiveModel;
7
8
/**
9
 * Class FeedbackAnswer. Answers relation to feedback request posts.
10
 * @package Apps\ActiveRecord
11
 * @property int $id
12
 * @property int $feedback_id
13
 * @property string $name
14
 * @property string $email
15
 * @property string $message
16
 * @property int $is_admin
17
 * @property int $user_id
18
 * @property string $ip
19
 * @property string $created_at
20
 * @property string $updated_at
21
 */
22
class FeedbackAnswer extends ActiveModel
23
{
24
    /**
25
     * Get post relation
26
     * @return ActiveModel|null
27
     */
28
    public function getFeedbackPost()
29
    {
30
        return FeedbackPost::find($this->feedback_id);
31
    }
32
}