| Total Complexity | 3 |
| Total Lines | 40 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 10 | class ContactController extends Controller |
||
| 11 | { |
||
| 12 | /** |
||
| 13 | * @var ContactServiceInterface |
||
| 14 | */ |
||
| 15 | private ContactServiceInterface $service; |
||
| 16 | |||
| 17 | /** |
||
| 18 | * ContactController constructor. |
||
| 19 | * |
||
| 20 | * @param ContactServiceInterface $service |
||
| 21 | */ |
||
| 22 | 2 | public function __construct(ContactServiceInterface $service) |
|
| 23 | { |
||
| 24 | 2 | $this->service = $service; |
|
| 25 | 2 | } |
|
| 26 | |||
| 27 | /** |
||
| 28 | * Returns user by id. |
||
| 29 | * |
||
| 30 | * @param string $id |
||
| 31 | * @return ContactResource |
||
| 32 | */ |
||
| 33 | 1 | public function show(string $id) |
|
| 37 | ); |
||
| 38 | } |
||
| 39 | |||
| 40 | /** |
||
| 41 | * Returns contacts by user. |
||
| 42 | * |
||
| 43 | * @return \Illuminate\Http\Resources\Json\AnonymousResourceCollection |
||
| 44 | */ |
||
| 45 | 1 | public function index() |
|
| 52 |