GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — master ( b864c9...ed9166 )
by butschster
12:41
created

DisplayColumnController::orderDown()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
cc 1
eloc 4
nc 1
nop 2
dl 0
loc 8
ccs 0
cts 6
cp 0
crap 2
rs 9.4285
c 0
b 0
f 0
1
<?php
2
3
namespace SleepingOwl\Admin\Http\Controllers;
4
5
use Illuminate\Routing\Controller;
6
use SleepingOwl\Admin\Traits\OrderableModel;
7
use SleepingOwl\Admin\Contracts\ModelConfigurationInterface;
8
9
class DisplayColumnController extends Controller
10
{
11
    /**
12
     * @param ModelConfigurationInterface $model
13
     * @param int $id
14
     *
15
     * @return \Illuminate\Http\RedirectResponse
16
     */
17
    public function orderUp(ModelConfigurationInterface $model, $id)
18
    {
19
        /** @var OrderableModel $instance */
20
        $instance = $model->getRepository()->find($id);
21
        $instance->moveUp();
22
23
        return back();
24
    }
25
26
    /**
27
     * @param ModelConfigurationInterface $model
28
     * @param int $id
29
     *
30
     * @return \Illuminate\Http\RedirectResponse
31
     */
32
    public function orderDown(ModelConfigurationInterface $model, $id)
33
    {
34
        /** @var OrderableModel $instance */
35
        $instance = $model->getRepository()->find($id);
36
        $instance->moveDown();
37
38
        return back();
39
    }
40
}
41