Passed
Pull Request — master (#17)
by Orkhan
03:43
created

CreatesEntity   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 12
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 2
dl 0
loc 12
rs 10
c 1
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A create() 0 3 1
1
<?php
2
3
namespace Orkhanahmadov\EloquentRepository\Repository\Concerns;
4
5
use Illuminate\Database\Eloquent\Model;
6
use Illuminate\Database\Eloquent\Builder;
7
8
/**
9
 * @property-read Builder|Model $model
10
 */
11
trait CreatesEntity
12
{
13
    /**
14
     * Creates model.
15
     *
16
     * @param mixed $properties
17
     *
18
     * @return Builder|Model
19
     */
20
    public function create($properties)
21
    {
22
        return $this->model->create($properties);
23
    }
24
}
25