1 | <?php |
||
2 | |||
3 | namespace Faithgen\Miscellaneous\Http\Resources; |
||
4 | |||
5 | use Illuminate\Http\Resources\Json\JsonResource; |
||
6 | use InnoFlash\LaraStart\Helper; |
||
0 ignored issues
–
show
|
|||
7 | |||
8 | class FAQ extends JsonResource |
||
9 | { |
||
10 | /** |
||
11 | * Transform the resource into an array. |
||
12 | * |
||
13 | * @param \Illuminate\Http\Request $request |
||
14 | * |
||
15 | * @return array |
||
16 | */ |
||
17 | public function toArray($request) |
||
18 | { |
||
19 | return [ |
||
20 | 'id' => $this->id, |
||
0 ignored issues
–
show
The property
id does not exist on Faithgen\Miscellaneous\Http\Resources\FAQ . Since you implemented __get , consider adding a @property annotation.
![]() |
|||
21 | 'question' => $this->question, |
||
0 ignored issues
–
show
The property
question does not exist on Faithgen\Miscellaneous\Http\Resources\FAQ . Since you implemented __get , consider adding a @property annotation.
![]() |
|||
22 | 'answer' => $this->answer, |
||
0 ignored issues
–
show
The property
answer does not exist on Faithgen\Miscellaneous\Http\Resources\FAQ . Since you implemented __get , consider adding a @property annotation.
![]() |
|||
23 | 'date' => Helper::getDates($this->created_at), |
||
0 ignored issues
–
show
The property
created_at does not exist on Faithgen\Miscellaneous\Http\Resources\FAQ . Since you implemented __get , consider adding a @property annotation.
![]() |
|||
24 | ]; |
||
25 | } |
||
26 | } |
||
27 |
The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g.
excluded_paths: ["lib/*"]
, you can move it to the dependency path list as follows:For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths