Passed
Pull Request — main (#29)
by Seth
01:25
created

FileController::index()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 1
nc 1
nop 0
dl 0
loc 4
rs 10
c 1
b 0
f 0
1
<?php
2
3
namespace SaasReady\Http\Controllers;
4
5
use Illuminate\Http\JsonResponse;
0 ignored issues
show
Bug introduced by
The type Illuminate\Http\JsonResponse was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
6
use Illuminate\Routing\Controller;
0 ignored issues
show
Bug introduced by
The type Illuminate\Routing\Controller was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
7
use SaasReady\Models\File;
8
9
class FileController extends Controller
10
{
11
    /**
12
     * Get a list of files
13
     */
14
    public function index(): JsonResponse
15
    {
16
        // TODO: implements
17
        return new JsonResponse();
18
    }
19
20
    public function show(File $file): JsonResponse
21
    {
22
        // TODO: implements
23
        return new JsonResponse();
24
    }
25
26
    /**
27
     * Upload a file
28
     */
29
    public function store(): JsonResponse
30
    {
31
        // TODO: implements
32
        return new JsonResponse();
33
    }
34
35
    public function destroy(File $file): JsonResponse
36
    {
37
        $file->delete();
38
39
        // TODO: implements
40
        return new JsonResponse();
41
    }
42
}
43