diff --git a/.github/workflows/php.yml b/.github/workflows/php.yml index b7eafb6..1665f2f 100644 --- a/.github/workflows/php.yml +++ b/.github/workflows/php.yml @@ -4,11 +4,17 @@ on: [push, pull_request] jobs: # Check there is no syntax errors in the project php-linter: - name: PHP Syntax check 7.4 => 8.2 + name: PHP Syntax check 7.2 => 8.5 runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v2.0.0 + uses: actions/checkout@v3.1.0 + + - name: PHP syntax checker 7.2 + uses: prestashop/github-action-php-lint/7.2@master + + - name: PHP syntax checker 7.3 + uses: prestashop/github-action-php-lint/7.3@master - name: PHP syntax checker 7.4 uses: prestashop/github-action-php-lint/7.4@master @@ -22,6 +28,15 @@ jobs: - name: PHP syntax checker 8.2 uses: prestashop/github-action-php-lint/8.2@master + - name: PHP syntax checker 8.3 + uses: prestashop/github-action-php-lint/8.3@master + + - name: PHP syntax checker 8.4 + uses: prestashop/github-action-php-lint/8.4@master + + - name: PHP syntax checker 8.5 + uses: prestashop/github-action-php-lint/8.5@master + # Check the PHP code follow the coding standards php-cs-fixer: name: PHP-CS-Fixer diff --git a/dashactivity.php b/dashactivity.php index d72ce25..5d677e8 100755 --- a/dashactivity.php +++ b/dashactivity.php @@ -159,7 +159,9 @@ public function hookDashboardData($params) explode(',', $maintenance_ips) ) ), - static fn ($item) => (string) $item !== '' + static function ($item) { + return ((string) $item) !== ''; + } ) ); }