* Make sure proper subfleets are returned as part of the user profile #848 * Formatting
This commit is contained in:
@@ -89,10 +89,7 @@ class UserController extends Controller
|
||||
*/
|
||||
public function get($id)
|
||||
{
|
||||
$user = $this->userRepo
|
||||
->with(['airline', 'bids', 'rank'])
|
||||
->find($id);
|
||||
|
||||
$user = $this->userSvc->getUser($id);
|
||||
return new UserResource($user);
|
||||
}
|
||||
|
||||
|
||||
@@ -31,6 +31,7 @@ class User extends Resource
|
||||
$res['airline'] = Airline::make($this->whenLoaded('airline'));
|
||||
$res['bids'] = UserBid::collection($this->whenLoaded('bids'));
|
||||
$res['rank'] = Rank::make($this->whenLoaded('rank'));
|
||||
$res['subfleets'] = Subfleet::make($this->whenLoaded('subfleets'));
|
||||
|
||||
return $res;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user