1 | <?php |
||
11 | class ImageController extends Controller |
||
12 | { |
||
13 | /** |
||
14 | * Service class for content images. |
||
15 | * |
||
16 | * @var \Larafolio\Http\Content\ContentImages |
||
17 | */ |
||
18 | protected $contentImages; |
||
19 | |||
20 | /** |
||
21 | * Construct. |
||
22 | * |
||
23 | * @param \Larafolio\Http\Content\ContentImages $contentImages Service class for content images. |
||
24 | */ |
||
25 | public function __construct(ContentImages $contentImages) |
||
31 | |||
32 | /** |
||
33 | * Update image name and caption. |
||
34 | * |
||
35 | * @param \Illuminate\Http\Request $request Request object. |
||
36 | * @param int $imageID ID of image to be updated. |
||
37 | * |
||
38 | * @return \Illuminate\Http\Response|bool |
||
39 | */ |
||
40 | public function update(Request $request, $imageID) |
||
58 | |||
59 | /** |
||
60 | * Remove image from portfolio. |
||
61 | * |
||
62 | * @param \Illuminate\Http\Request $request Request object. |
||
63 | * @param int $imageID ID of image to be removed. |
||
64 | * |
||
65 | * @return \Illuminate\Http\Response|bool |
||
66 | */ |
||
67 | public function destroy(Request $request, $imageID) |
||
79 | |||
80 | /** |
||
81 | * Update an image path. |
||
82 | * |
||
83 | * @param \Illuminate\Http\Request $request Request from user. |
||
84 | * @param \Larafolio\Models\Image $image Image to update. |
||
85 | */ |
||
86 | protected function updateImageInstance(Request $request, Image $image) |
||
94 | } |
||
95 |
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: