Skip to content

Commit 0a450ad

Browse files
authored
Merge pull request #3213 from yajra/ci-patch
fix: static analysis
2 parents 2a42378 + a17f045 commit 0a450ad

10 files changed

+22
-18
lines changed

.gitattributes

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
.gitattributes export-ignore
77
.gitignore export-ignore
88
.scrutinizer.yml export-ignore
9-
.styleci.yml export-ignore
109
phpstan.neon.dist export-ignore
1110
phpunit.xml.dist export-ignore
11+
pint.json export-ignore
12+
rector.php export-ignore

.github/workflows/continuous-integration.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,14 +14,14 @@ jobs:
1414
strategy:
1515
fail-fast: true
1616
matrix:
17-
php: [8.2, 8.3]
17+
php: [8.2, 8.3, 8.4]
1818
stability: [prefer-stable]
1919

2020
name: PHP ${{ matrix.php }} - ${{ matrix.stability }}
2121

2222
steps:
2323
- name: Checkout code
24-
uses: actions/checkout@v2
24+
uses: actions/checkout@v4
2525

2626
- name: Setup PHP
2727
uses: shivammathur/setup-php@v2

.github/workflows/pint.yml

+9-1
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,21 @@ on:
77
jobs:
88
phplint:
99
runs-on: ubuntu-latest
10+
11+
permissions:
12+
contents: write
13+
1014
steps:
1115
- uses: actions/checkout@v4
16+
with:
17+
ref: ${{ github.head_ref }}
18+
1219
- name: "laravel-pint"
13-
uses: aglipanci/laravel-pint-action@2.0.0
20+
uses: aglipanci/laravel-pint-action@latest
1421
with:
1522
preset: laravel
1623
verboseMode: true
24+
1725
- uses: stefanzweifel/git-auto-commit-action@v5
1826
with:
1927
commit_message: "fix: pint"

.github/workflows/static-analysis.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,12 @@ jobs:
2929
strategy:
3030
fail-fast: true
3131
matrix:
32-
php: [8.2, 8.3]
32+
php: [8.2, 8.3, 8.4]
3333
stability: [prefer-stable]
3434

3535
steps:
3636
- name: Checkout code
37-
uses: actions/checkout@v2
37+
uses: actions/checkout@v4
3838

3939
- name: Setup PHP
4040
uses: shivammathur/setup-php@v2

.styleci.yml

-1
This file was deleted.

phpstan.neon.dist

+1-2
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,7 @@ parameters:
1010

1111
ignoreErrors:
1212
- '#Unsafe usage of new static\(\).#'
13+
- identifier: missingType.iterableValue
1314

1415
excludePaths:
1516
- src/helper.php
16-
17-
checkMissingIterableValueType: false

sonar-project.properties

-3
This file was deleted.

src/Contracts/DataTable.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ interface DataTable
1010
/**
1111
* Get results.
1212
*
13-
* @return \Illuminate\Support\Collection<int, array>
13+
* @return \Illuminate\Support\Collection<int, \stdClass>|\Illuminate\Support\Collection<array-key, array>
1414
*/
1515
public function results(): Collection;
1616

src/QueryDataTable.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ public function make(bool $mDataSupport = true): JsonResponse
130130
/**
131131
* Get paginated results.
132132
*
133-
* @return \Illuminate\Support\Collection<int, array>
133+
* @return \Illuminate\Support\Collection<int, \stdClass>
134134
*/
135135
public function results(): Collection
136136
{

src/config/datatables.php

+4-4
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,10 @@
5757
* Note, only change this if you know what you are doing!
5858
*/
5959
'builders' => [
60-
//Illuminate\Database\Eloquent\Relations\Relation::class => 'eloquent',
61-
//Illuminate\Database\Eloquent\Builder::class => 'eloquent',
62-
//Illuminate\Database\Query\Builder::class => 'query',
63-
//Illuminate\Support\Collection::class => 'collection',
60+
// Illuminate\Database\Eloquent\Relations\Relation::class => 'eloquent',
61+
// Illuminate\Database\Eloquent\Builder::class => 'eloquent',
62+
// Illuminate\Database\Query\Builder::class => 'query',
63+
// Illuminate\Support\Collection::class => 'collection',
6464
],
6565

6666
/*

0 commit comments

Comments
 (0)