Remove unnecessary function

This commit is contained in:
Dane Everitt
2021-08-07 14:32:40 -07:00
parent bbf2f33c5e
commit fdd90b3be7
37 changed files with 92 additions and 136 deletions

View File

@@ -43,7 +43,7 @@ class RoleController extends ApplicationApiController
->paginate($perPage);
return $this->fractal->collection($roles)
->transformWith($this->getTransformer(AdminRoleTransformer::class))
->transformWith(AdminRoleTransformer::class)
->toArray();
}
@@ -55,7 +55,7 @@ class RoleController extends ApplicationApiController
public function view(GetRoleRequest $request, AdminRole $role): array
{
return $this->fractal->item($role)
->transformWith($this->getTransformer(AdminRoleTransformer::class))
->transformWith(AdminRoleTransformer::class)
->toArray();
}
@@ -72,7 +72,7 @@ class RoleController extends ApplicationApiController
$role = AdminRole::query()->create($data);
return $this->fractal->item($role)
->transformWith($this->getTransformer(AdminRoleTransformer::class))
->transformWith(AdminRoleTransformer::class)
->respond(JsonResponse::HTTP_CREATED);
}
@@ -86,7 +86,7 @@ class RoleController extends ApplicationApiController
$role->update($request->validated());
return $this->fractal->item($role)
->transformWith($this->getTransformer(AdminRoleTransformer::class))
->transformWith(AdminRoleTransformer::class)
->toArray();
}