middleware('auth'); View::share('is_admin', true); } public function index() { $this->authorizeAccessToAdminPanel(); $comments = PhotoComment::with('photo') ->with('photo.album') ->orderBy('created_at', 'desc') ->paginate(UserConfig::get('items_per_page')); return Theme::render('admin.list_comments', [ 'comments' => $comments ]); } }