src/Http/Controllers/HandleUploads.php
public function getFiles(int $id)
    {
        if(!$object = $this->repository->find($id)) {
            abort(404);
        }

        $media = $object->getMedia();

        return MediaResource::collection($media);
    }
public function getFiles(int $id)
    {
        if(!$object = $this->repository->find($id)) {
            abort(404);
        }

        $media = $object->getMedia();

        return MediaResource::collection($media);
    }
Get all Files

@param int $id
@return AnonymousResourceCollection|MediaResource[]