Passed
Push — master ( 1ffd02...b93f0b )
by Bertrand
06:21
created

WikiUserRole::__construct()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
c 1
b 0
f 0
nc 1
nop 1
dl 0
loc 3
rs 10
1
<?php
2
3
4
namespace App\Src\UseCases\Domain\Users\Dto;
5
6
7
use Illuminate\Contracts\Support\Arrayable;
8
9
class WikiUserRole implements Role, Arrayable
10
{
11
    public $role;
12
13
    public function __construct(string $role)
14
    {
15
        $this->role = $role;
16
    }
17
18
    public function toArray()
19
    {
20
        return [
21
            'role' => $this->role
22
        ];
23
    }
24
}
25