| Conditions | 1 |
| Paths | 1 |
| Total Lines | 8 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 0 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php |
||
| 55 | public function create(Request $request) |
||
| 56 | { |
||
| 57 | $this->validate($request, [ |
||
| 58 | 'title' => 'required|unique:notifications|max:255', |
||
| 59 | 'body' => 'required', |
||
| 60 | ]); |
||
| 61 | return response()->json($this->api->be(auth()->user())->put('/api/notifications', ['title' => $request->title, 'body' => $request->body])); |
||
| 62 | } |
||
| 63 | |||
| 65 |
This check compares the return type specified in the
@returnannotation of a function or method doc comment with the types returned by the function and raises an issue if they mismatch.