Skip to content

Commit ded303f

Browse files
committed
Merged branch '4.6'
2 parents 63c3a86 + a833a94 commit ded303f

File tree

4 files changed

+127
-6
lines changed

4 files changed

+127
-6
lines changed

phpstan-baseline-gte-8.0.neon

Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
parameters:
2+
ignoreErrors:
3+
-
4+
message: '#^Access to an undefined property DOMNode\:\:\$data\.$#'
5+
identifier: property.notFound
6+
count: 2
7+
path: src/lib/Input/Handler/Xml.php
8+
9+
-
10+
message: '#^Access to an undefined property DOMNode\:\:\$tagName\.$#'
11+
identifier: property.notFound
12+
count: 2
13+
path: src/lib/Input/Handler/Xml.php
14+
15+
-
16+
message: '#^Access to an undefined property DOMNode\:\:\$wholeText\.$#'
17+
identifier: property.notFound
18+
count: 2
19+
path: src/lib/Input/Handler/Xml.php
20+
21+
-
22+
message: '#^Call to an undefined method DOMNode\:\:getAttribute\(\)\.$#'
23+
identifier: method.notFound
24+
count: 1
25+
path: src/lib/Input/Handler/Xml.php
26+
27+
-
28+
message: '#^Call to an undefined method DOMNode\:\:hasAttribute\(\)\.$#'
29+
identifier: method.notFound
30+
count: 1
31+
path: src/lib/Input/Handler/Xml.php
32+
33+
-
34+
message: '#^Parameter \#1 \$domElement of method Ibexa\\Rest\\Input\\Handler\\Xml\:\:parseFieldTypeHash\(\) expects DOMElement, DOMNode given\.$#'
35+
identifier: argument.type
36+
count: 1
37+
path: src/lib/Input/Handler/Xml.php
38+
39+
-
40+
message: '#^Parameter \#1 \$array of function array_slice expects array, iterable\<int, Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\Relation\> given\.$#'
41+
identifier: argument.type
42+
count: 1
43+
path: src/lib/Server/Controller/Content.php
44+
45+
-
46+
message: '#^Parameter \#2 \$string of function explode expects string, string\|null given\.$#'
47+
identifier: argument.type
48+
count: 4
49+
path: src/lib/Server/Controller/Content.php
50+
51+
-
52+
message: '#^Parameter \#2 \.\.\.\$arrays of function array_merge expects array, iterable\<Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentType\> given\.$#'
53+
identifier: argument.type
54+
count: 1
55+
path: src/lib/Server/Controller/ContentType.php
56+
57+
-
58+
message: '#^Parameter \#1 \$array of function array_slice expects array, iterable\<Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Role\> given\.$#'
59+
identifier: argument.type
60+
count: 1
61+
path: src/lib/Server/Controller/Role.php
62+
63+
-
64+
message: '#^Parameter \#1 \.\.\.\$arrays of function array_merge expects array, iterable\<Ibexa\\Contracts\\Core\\Repository\\Values\\User\\Policy\> given\.$#'
65+
identifier: argument.type
66+
count: 1
67+
path: src/lib/Server/Controller/Role.php
68+
69+
-
70+
message: '#^Parameter \#2 \$error_level of function trigger_error expects int, string given\.$#'
71+
identifier: argument.type
72+
count: 4
73+
path: src/lib/Server/Controller/User.php
74+
75+
-
76+
message: '#^Parameter \#1 \$message of method Psr\\Log\\LoggerInterface\:\:error\(\) expects string\|Stringable, Symfony\\Component\\Security\\Core\\User\\UserInterface\|null given\.$#'
77+
identifier: argument.type
78+
count: 1
79+
path: src/lib/Server/Security/RestAuthenticator.php
80+
81+
-
82+
message: '#^Parameter \#1 \$string of function base64_encode expects string, string\|false given\.$#'
83+
identifier: argument.type
84+
count: 1
85+
path: tests/bundle/Functional/BinaryContentTest.php

phpstan-baseline-gte-8.1.neon

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
parameters:
2+
ignoreErrors:
3+
-
4+
message: '#^Strict comparison using \!\=\= between DOMNamedNodeMap and null will always evaluate to true\.$#'
5+
identifier: notIdentical.alwaysTrue
6+
count: 1
7+
path: src/lib/Input/Handler/Xml.php

phpstan-baseline.neon

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -192,12 +192,6 @@ parameters:
192192
count: 1
193193
path: src/lib/Input/Handler/Xml.php
194194

195-
-
196-
message: '#^Cannot access an offset on array\|bool\|float\|int\|string\.$#'
197-
identifier: offsetAccess.nonOffsetAccessible
198-
count: 1
199-
path: src/lib/Input/Handler/Xml.php
200-
201195
-
202196
message: '#^Method Ibexa\\Rest\\Input\\Handler\\Xml\:\:convert\(\) return type has no value type specified in iterable type array\.$#'
203197
identifier: missingType.iterableValue
@@ -1614,6 +1608,12 @@ parameters:
16141608
count: 1
16151609
path: tests/bundle/Functional/SessionTest.php
16161610

1611+
-
1612+
message: '#^Argument of an invalid type array\<SimpleXMLElement\>\|null supplied for foreach, only iterables are supported\.$#'
1613+
identifier: foreach.nonIterable
1614+
count: 1
1615+
path: tests/bundle/Functional/SortClauseTest.php
1616+
16171617
-
16181618
message: '#^Access to an undefined property object\:\:\$line\.$#'
16191619
identifier: property.notFound

phpstan-baseline.neon.php

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
<?php
2+
3+
/**
4+
* @copyright Copyright (C) Ibexa AS. All rights reserved.
5+
* @license For full copyright and license information view LICENSE file distributed with this source code.
6+
*/
7+
declare(strict_types=1);
8+
9+
$includes = [];
10+
if (PHP_VERSION_ID < 8_00_00) {
11+
$includes[] = __DIR__ . '/phpstan-baseline-7.4.neon';
12+
}
13+
14+
if (PHP_VERSION_ID >= 8_00_00) {
15+
$includes[] = __DIR__ . '/phpstan-baseline-gte-8.0.neon';
16+
}
17+
18+
if (PHP_VERSION_ID >= 8_00_00 && PHP_VERSION_ID < 8_01_00) {
19+
$includes[] = __DIR__ . '/phpstan-baseline-8.0-specific.neon';
20+
}
21+
22+
if (PHP_VERSION_ID >= 8_01_00) {
23+
$includes[] = __DIR__ . '/phpstan-baseline-gte-8.1.neon';
24+
}
25+
26+
$config = [];
27+
$config['includes'] = $includes;
28+
29+
return $config;

0 commit comments

Comments
 (0)