/** * Display the specified resource. * * @param int $id * @return Response */ public function show($id) { $journal = Journal::with('user')->findOrFail($id); $owner = false; if (Authorizer::getResourceOwnerId() == $journal->user_id) { $owner = true; } return Response::json(['journals' => $journal, 'isOwner' => $owner], 200); }