| 1 | <?php |
||
| 8 | class ImageController extends Controller |
||
| 9 | { |
||
| 10 | /** |
||
| 11 | * Update image name and caption. |
||
| 12 | * |
||
| 13 | * @param \Illuminate\Http\Request $request Request object. |
||
| 14 | * @param Image $image Image to be updated. |
||
| 15 | * |
||
| 16 | * @return \Illuminate\Http\Response |
||
| 17 | */ |
||
| 18 | public function update(Request $request, Image $image) |
||
| 30 | |||
| 31 | /** |
||
| 32 | * Remove image from portfolio. |
||
| 33 | * |
||
| 34 | * @param Image $image Image to be removed. |
||
| 35 | * |
||
| 36 | * @return \Illuminate\Http\Response |
||
| 37 | */ |
||
| 38 | public function destroy(Request $request, Image $image) |
||
| 48 | } |
||
| 49 |
It seems like the type of the argument is not accepted by the function/method which you are calling.
In some cases, in particular if PHP’s automatic type-juggling kicks in this might be fine. In other cases, however this might be a bug.
We suggest to add an explicit type cast like in the following example: