Conditions | 3 |
Paths | 4 |
Total Lines | 20 |
Code Lines | 13 |
Lines | 0 |
Ratio | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
17 | public function updatePosition(Request $request) |
||
18 | { |
||
19 | try { |
||
20 | $position = 1; |
||
21 | foreach ($request->columns as $id) { |
||
22 | $configStatus = ConfigStatus::find($id); |
||
23 | $configStatus->position = $position; |
||
24 | $configStatus->save(); |
||
25 | ++$position; |
||
26 | } |
||
27 | |||
28 | return response()->json([ |
||
29 | 'success' => true, |
||
30 | ]); |
||
31 | } catch (\Exception $e) { |
||
32 | return response()->json([ |
||
33 | 'success' => false, |
||
34 | ]); |
||
35 | } |
||
36 | } |
||
37 | } |
||
38 |
This check compares the return type specified in the
@return
annotation of a function or method doc comment with the types returned by the function and raises an issue if they mismatch.