Skip to content

Commit f543350

Browse files
committed
build(app): Fixing more analyses errors
1 parent 5a81d90 commit f543350

File tree

7 files changed

+10
-20
lines changed

7 files changed

+10
-20
lines changed

tests/system/CodeIgniterTest.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1004,12 +1004,12 @@ public function testRouteAttributeCacheIntegration(): void
10041004

10051005
// Second request - should return cached version with same timestamp
10061006
$this->resetServices();
1007-
$_SERVER['argv'] = ['index.php', 'attribute/cached'];
1008-
$_SERVER['argc'] = 2;
1007+
$_SERVER['argv'] = ['index.php', 'attribute/cached'];
1008+
$_SERVER['argc'] = 2;
10091009
Services::superglobals()->setServer('REQUEST_URI', '/attribute/cached');
10101010
Services::superglobals()->setServer('SCRIPT_NAME', '/index.php');
10111011
Services::superglobals()->setServer('REQUEST_METHOD', 'GET');
1012-
$this->codeigniter = new MockCodeIgniter(new App());
1012+
$this->codeigniter = new MockCodeIgniter(new App());
10131013

10141014
$routes = service('routes');
10151015
$routes->get('attribute/cached', '\Tests\Support\Router\Controllers\AttributeController::cached');

tests/system/Router/Attributes/CacheTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313

1414
namespace CodeIgniter\Router\Attributes;
1515

16-
use CodeIgniter\HTTP\ResponseInterface;
1716
use CodeIgniter\HTTP\IncomingRequest;
17+
use CodeIgniter\HTTP\ResponseInterface;
1818
use CodeIgniter\HTTP\SiteURI;
1919
use CodeIgniter\HTTP\UserAgent;
2020
use CodeIgniter\Test\CIUnitTestCase;

tests/system/Router/Attributes/FilterTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313

1414
namespace CodeIgniter\Router\Attributes;
1515

16-
use CodeIgniter\HTTP\ResponseInterface;
1716
use CodeIgniter\HTTP\IncomingRequest;
17+
use CodeIgniter\HTTP\ResponseInterface;
1818
use CodeIgniter\HTTP\SiteURI;
1919
use CodeIgniter\HTTP\UserAgent;
2020
use CodeIgniter\Test\CIUnitTestCase;

tests/system/Router/Attributes/RestrictTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@
1313

1414
namespace CodeIgniter\Router\Attributes;
1515

16-
use CodeIgniter\HTTP\ResponseInterface;
1716
use CodeIgniter\Exceptions\PageNotFoundException;
1817
use CodeIgniter\HTTP\IncomingRequest;
18+
use CodeIgniter\HTTP\ResponseInterface;
1919
use CodeIgniter\HTTP\SiteURI;
2020
use CodeIgniter\HTTP\UserAgent;
2121
use CodeIgniter\Test\CIUnitTestCase;

utils/phpstan-baseline/empty.notAllowed.neon

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# total 231 errors
1+
# total 230 errors
22

33
parameters:
44
ignoreErrors:
@@ -287,11 +287,6 @@ parameters:
287287
count: 4
288288
path: ../../system/RESTful/BaseResource.php
289289

290-
-
291-
message: '#^Construct empty\(\) is not allowed\. Use more strict comparison\.$#'
292-
count: 1
293-
path: ../../system/Router/Attributes/Filter.php
294-
295290
-
296291
message: '#^Construct empty\(\) is not allowed\. Use more strict comparison\.$#'
297292
count: 6
Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
1-
# total 1 error
1+
# total 0 errors
22

33
parameters:
4-
ignoreErrors:
5-
-
6-
message: '#^Comparison operation "\>\=" between int\<3, max\> and 3 is always true\.$#'
7-
count: 1
8-
path: ../../system/Router/Attributes/Restrict.php
4+
ignoreErrors: []

utils/phpstan-baseline/loader.neon

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# total 2817 errors
1+
# total 2815 errors
22

33
includes:
44
- argument.type.neon
@@ -10,7 +10,6 @@ includes:
1010
- codeigniter.superglobalAccessAssign.neon
1111
- deadCode.unreachable.neon
1212
- empty.notAllowed.neon
13-
- greaterOrEqual.alwaysTrue.neon
1413
- isset.property.neon
1514
- method.alreadyNarrowedType.neon
1615
- method.childParameterType.neon

0 commit comments

Comments
 (0)