faithgen /
events
| 1 | <?php |
||
| 2 | |||
| 3 | namespace Innoflash\Events\Http\Resources; |
||
| 4 | |||
| 5 | use FaithGen\SDK\Helpers\ImageHelper; |
||
| 6 | use Illuminate\Http\Resources\Json\JsonResource; |
||
| 7 | |||
| 8 | class Guest extends JsonResource |
||
| 9 | { |
||
| 10 | /** |
||
| 11 | * Transform the resource into an array. |
||
| 12 | * |
||
| 13 | * @param \Illuminate\Http\Request $request |
||
| 14 | * @return array |
||
| 15 | */ |
||
| 16 | public function toArray($request) |
||
| 17 | { |
||
| 18 | return array_merge(parent::toArray($request), [ |
||
| 19 | 'avatar' => ImageHelper::getImage('events', $this->image, config('faithgen-sdk.ministries-server')), |
||
|
0 ignored issues
–
show
Bug
Best Practice
introduced
by
Loading history...
|
|||
| 20 | ]); |
||
| 21 | } |
||
| 22 | } |
||
| 23 |