コード例 #1
0
 /**
  * Obtained from .php_cs configuration file.
  *
  * @param  FileInterface $file
  * @return bool
  */
 public function canReview(FileInterface $file)
 {
     return in_array($file->getExtension(), ['php', 'phtml', 'xml', 'yml']);
 }
コード例 #2
0
 /**
  * @param FileInterface $file
  *
  * @return bool
  */
 protected function canReviewFile(FileInterface $file)
 {
     return $file->getExtension() === 'php';
 }
コード例 #3
0
 /**
  * Determins if the given file should be revewed.
  *
  * @param  FileInterface $file
  * @return bool
  */
 public function canReviewFile(FileInterface $file)
 {
     return $file->getExtension() === 'php' && substr($file->getFileName(), -strlen('blade.php')) != 'blade.php';
 }
コード例 #4
0
ファイル: PhpLintReview.php プロジェクト: Flesh192/magento
 /**
  * Determins if a given file should be reviewed.
  *
  * @param  FileInterface $file
  * @return bool
  */
 public function canReview(FileInterface $file)
 {
     $extension = $file->getExtension();
     return $extension === 'php' || $extension === 'phtml';
 }
コード例 #5
0
 /**
  * Determins if a given file should be reviewed.
  *
  * @param  FileInterface $file
  * @return bool
  */
 public function canReview(FileInterface $file)
 {
     return $file->getExtension() === 'php';
 }