/**
  * @param string $revised
  * @return \Illuminate\View\View
  */
 public function index($revised = "pending")
 {
     $revised = $this->checkRevised($revised);
     if ($revised === false) {
         abort(404);
     }
     $data = ['comments' => $this->comment->byRevised($revised)->paginate($this->config->items_per_page), 'revised' => $revised];
     return view('blogify::admin.comments.index', $data);
 }
 /**
  * @return void
  */
 private function buildDataArrayForAuthor()
 {
     $this->data['published_posts'] = $this->post->where('publish_date', '<=', date('Y-m-d H:i:s'))->forAuthor()->count();
     $this->data['pending_review_posts'] = $this->post->whereStatusId(2)->forAuthor()->count();
     $post_ids = $this->post->forAuthor()->lists('id');
     $this->data['pending_comments'] = $this->comment->byRevised(1)->whereIn('post_id', $post_ids)->count();
 }