Remove unnecessary function

This commit is contained in:
Dane Everitt 2021-08-07 14:32:40 -07:00
parent bbf2f33c5e
commit fdd90b3be7
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
37 changed files with 92 additions and 136 deletions

View file

@ -52,7 +52,7 @@ class EggController extends ApplicationApiController
}
return $this->fractal->collection($eggs)
->transformWith($this->getTransformer(EggTransformer::class))
->transformWith(EggTransformer::class)
->toArray();
}
@ -64,7 +64,7 @@ class EggController extends ApplicationApiController
public function view(GetEggRequest $request, Egg $egg): array
{
return $this->fractal->item($egg)
->transformWith($this->getTransformer(EggTransformer::class))
->transformWith(EggTransformer::class)
->toArray();
}
@ -78,7 +78,7 @@ class EggController extends ApplicationApiController
$egg = Egg::query()->create($request->validated());
return $this->fractal->item($egg)
->transformWith($this->getTransformer(EggTransformer::class))
->transformWith(EggTransformer::class)
->respond(JsonResponse::HTTP_CREATED);
}
@ -92,7 +92,7 @@ class EggController extends ApplicationApiController
$egg->update($request->validated());
return $this->fractal->item($egg)
->transformWith($this->getTransformer(EggTransformer::class))
->transformWith(EggTransformer::class)
->toArray();
}