コード例 #1
0
ファイル: Comment.php プロジェクト: voh/FoolFuuka
 public function getReports()
 {
     if ($this->reports === null) {
         if ($this->getAuth()->hasAccess('comment.reports')) {
             $reports = $this->report_coll->getByDocId($this->radix, $this->comment->doc_id);
             if ($this->bulk->media) {
                 $reports += $this->report_coll->getByMediaId($this->radix, $this->bulk->media->media_id);
             }
             $this->reports = $reports;
         } else {
             $this->reports = [];
         }
     }
     return $this->reports;
 }