Merge #20239 - Update PHPStan
Pull-request: #20239 Signed-off-by: William Desportes <williamdes@wdes.fr>
This commit is contained in:
commit
8ae46b07fa
10
composer.lock
generated
10
composer.lock
generated
@ -5420,11 +5420,11 @@
|
||||
},
|
||||
{
|
||||
"name": "phpstan/phpstan",
|
||||
"version": "2.1.38",
|
||||
"version": "2.1.41",
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/phpstan/phpstan/zipball/dfaf1f530e1663aa167bc3e52197adb221582629",
|
||||
"reference": "dfaf1f530e1663aa167bc3e52197adb221582629",
|
||||
"url": "https://api.github.com/repos/phpstan/phpstan/zipball/a2eae8f20856b3afe74bf1f9726ce8c11438e300",
|
||||
"reference": "a2eae8f20856b3afe74bf1f9726ce8c11438e300",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@ -5469,7 +5469,7 @@
|
||||
"type": "github"
|
||||
}
|
||||
],
|
||||
"time": "2026-01-30T17:12:46+00:00"
|
||||
"time": "2026-03-16T18:24:10+00:00"
|
||||
},
|
||||
{
|
||||
"name": "phpstan/phpstan-deprecation-rules",
|
||||
@ -8910,5 +8910,5 @@
|
||||
"platform-overrides": {
|
||||
"php": "8.2.99"
|
||||
},
|
||||
"plugin-api-version": "2.6.0"
|
||||
"plugin-api-version": "2.9.0"
|
||||
}
|
||||
|
||||
@ -471,6 +471,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/Config/Form.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$keys of function array_combine expects an array of values castable to string, list\<mixed\> given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Config/Form.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$keys of function array_combine expects array\<int\|string\>, list\<mixed\> given\.$#'
|
||||
identifier: argument.type
|
||||
@ -835,7 +841,7 @@ parameters:
|
||||
path: src/Config/Settings/Server.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$callback of function array_map expects \(callable\(mixed\)\: mixed\)\|null, Closure\(bool\|float\|int\|resource\|string\|null\)\: string given\.$#'
|
||||
message: '#^Parameter \#1 \$callback of function array_map expects \(callable\(mixed\)\: mixed\)\|null, Closure\(bool\|float\|GMP\|int\|resource\|string\|null\)\: string given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Config/Settings/Server.php
|
||||
@ -1209,12 +1215,6 @@ parameters:
|
||||
count: 21
|
||||
path: src/ConfigStorage/Relation.php
|
||||
|
||||
-
|
||||
message: '#^Do\-while loop condition is always false\.$#'
|
||||
identifier: doWhile.alwaysFalse
|
||||
count: 1
|
||||
path: src/ConfigStorage/Relation.php
|
||||
|
||||
-
|
||||
message: '#^Method PhpMyAdmin\\ConfigStorage\\Relation\:\:getChildReferences\(\) should return array\<list\<array\<mixed\>\>\> but returns array\<mixed\>\.$#'
|
||||
identifier: return.type
|
||||
@ -1323,6 +1323,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/ConfigStorage/Relation.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in &&, mixed given on the right side\.$#'
|
||||
identifier: booleanAnd.rightNotBoolean
|
||||
count: 18
|
||||
path: src/ConfigStorage/RelationParameters.php
|
||||
|
||||
-
|
||||
message: '''
|
||||
#^Call to deprecated method getInstance\(\) of class PhpMyAdmin\\Config\:
|
||||
@ -2259,6 +2265,24 @@ parameters:
|
||||
count: 1
|
||||
path: src/Controllers/Server/DatabasesController.php
|
||||
|
||||
-
|
||||
message: '#^Offset ''Do_DB'' might not exist on array\{status\: true, Do_DB\?\: array\<string\>, Ignore_DB\?\: array\<string\>\}\.$#'
|
||||
identifier: offsetAccess.notFound
|
||||
count: 2
|
||||
path: src/Controllers/Server/DatabasesController.php
|
||||
|
||||
-
|
||||
message: '#^Offset ''Ignore_DB'' might not exist on array\{status\: true, Do_DB\?\: array\<string\>, Ignore_DB\?\: array\<string\>\}\.$#'
|
||||
identifier: offsetAccess.notFound
|
||||
count: 1
|
||||
path: src/Controllers/Server/DatabasesController.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in an if condition, mixed given\.$#'
|
||||
identifier: if.condNotBoolean
|
||||
count: 1
|
||||
path: src/Controllers/Server/DatabasesController.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$params of static method PhpMyAdmin\\Url\:\:getCommonRaw\(\) expects array\<int\|string, bool\|int\|string\>, array\<string, mixed\> given\.$#'
|
||||
identifier: argument.type
|
||||
@ -2274,13 +2298,13 @@ parameters:
|
||||
-
|
||||
message: '#^Parameter \#1 \$value of function count expects array\|Countable, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
count: 2
|
||||
count: 1
|
||||
path: src/Controllers/Server/DatabasesController.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#2 \$haystack of function array_search expects array, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
count: 4
|
||||
count: 2
|
||||
path: src/Controllers/Server/DatabasesController.php
|
||||
|
||||
-
|
||||
@ -2331,12 +2355,6 @@ parameters:
|
||||
count: 1
|
||||
path: src/Controllers/Server/PrivilegesController.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in an if condition, mixed given\.$#'
|
||||
identifier: if.condNotBoolean
|
||||
count: 1
|
||||
path: src/Controllers/Server/ReplicationController.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#2 \$serverReplicaStatus of method PhpMyAdmin\\Replication\\ReplicationGui\:\:getHtmlForReplicaConfiguration\(\) expects bool, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
@ -2436,7 +2454,7 @@ parameters:
|
||||
-
|
||||
message: '#^Only booleans are allowed in an if condition, mixed given\.$#'
|
||||
identifier: if.condNotBoolean
|
||||
count: 2
|
||||
count: 1
|
||||
path: src/Controllers/Server/Status/StatusController.php
|
||||
|
||||
-
|
||||
@ -3381,6 +3399,12 @@ parameters:
|
||||
count: 2
|
||||
path: src/Controllers/Table/Structure/SaveController.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in an if condition, mixed given\.$#'
|
||||
identifier: if.condNotBoolean
|
||||
count: 1
|
||||
path: src/Controllers/Table/Structure/SaveController.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$identifier of static method PhpMyAdmin\\Util\:\:backquote\(\) expects string\|Stringable\|null, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
@ -4080,6 +4104,24 @@ parameters:
|
||||
count: 1
|
||||
path: src/CreateAddField.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in &&, mixed given on the right side\.$#'
|
||||
identifier: booleanAnd.rightNotBoolean
|
||||
count: 1
|
||||
path: src/CreateAddField.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in a negated boolean, mixed given\.$#'
|
||||
identifier: booleanNot.exprNotBoolean
|
||||
count: 1
|
||||
path: src/CreateAddField.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in an if condition, mixed given\.$#'
|
||||
identifier: if.condNotBoolean
|
||||
count: 2
|
||||
path: src/CreateAddField.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$collation of static method PhpMyAdmin\\Util\:\:getCharsetQueryPart\(\) expects string, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
@ -4680,6 +4722,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/Database/Routines.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#2 \$array of function implode expects array\<string\>, array\<mixed, mixed\> given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Database/Routines.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#2 \$itemParamDir of method PhpMyAdmin\\Database\\Routines\:\:processParamsAndBuild\(\) expects array\<string\>, array\<mixed, mixed\> given\.$#'
|
||||
identifier: argument.type
|
||||
@ -4728,6 +4776,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/Database/Routines.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$array of function array_intersect expects an array of values castable to string, array\<mixed, mixed\> given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Database/Search.php
|
||||
|
||||
-
|
||||
message: '#^Property PhpMyAdmin\\Database\\Search\:\:\$criteriaTables \(array\<string\>\) does not accept array\<mixed\>\.$#'
|
||||
identifier: assign.propertyType
|
||||
@ -4776,18 +4830,6 @@ parameters:
|
||||
count: 1
|
||||
path: src/Dbal/DatabaseInterface.php
|
||||
|
||||
-
|
||||
message: '#^Cannot access an offset on mixed\.$#'
|
||||
identifier: offsetAccess.nonOffsetAccessible
|
||||
count: 1
|
||||
path: src/Dbal/DatabaseInterface.php
|
||||
|
||||
-
|
||||
message: '#^Cannot access offset string\|null on mixed\.$#'
|
||||
identifier: offsetAccess.nonOffsetAccessible
|
||||
count: 2
|
||||
path: src/Dbal/DatabaseInterface.php
|
||||
|
||||
-
|
||||
message: '#^Cannot cast mixed to string\.$#'
|
||||
identifier: cast.string
|
||||
@ -4836,6 +4878,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/Dbal/DatabaseInterface.php
|
||||
|
||||
-
|
||||
message: '#^Offset string\|null on array\{\} in isset\(\) does not exist\.$#'
|
||||
identifier: isset.offset
|
||||
count: 1
|
||||
path: src/Dbal/DatabaseInterface.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in &&, int\|false given on the left side\.$#'
|
||||
identifier: booleanAnd.leftNotBoolean
|
||||
@ -4902,6 +4950,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/Dbal/DatabaseInterface.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#2 \$arrays of function array_diff expects an array of values castable to string, array given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Dbal/DatabaseInterface.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#2 \$callback of function usort contains unresolvable type\.$#'
|
||||
identifier: argument.unresolvableType
|
||||
@ -5082,7 +5136,7 @@ parameters:
|
||||
-
|
||||
message: '#^Cannot access offset ''max_rows'' on mixed\.$#'
|
||||
identifier: offsetAccess.nonOffsetAccessible
|
||||
count: 19
|
||||
count: 14
|
||||
path: src/Display/Results.php
|
||||
|
||||
-
|
||||
@ -5766,6 +5820,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/Export/Export.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#2 \$array of function implode expects array\<string\>, array\<mixed\> given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Export/Export.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#2 \$dbAlias of method PhpMyAdmin\\Plugins\\ExportPlugin\:\:exportDBCreate\(\) expects string, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
@ -6465,6 +6525,18 @@ parameters:
|
||||
count: 1
|
||||
path: src/Gis/GisMultiPolygon.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in a negated boolean, mixed given\.$#'
|
||||
identifier: booleanNot.exprNotBoolean
|
||||
count: 2
|
||||
path: src/Gis/GisMultiPolygon.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in an if condition, mixed given\.$#'
|
||||
identifier: if.condNotBoolean
|
||||
count: 1
|
||||
path: src/Gis/GisMultiPolygon.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$point of method PhpMyAdmin\\Gis\\GisGeometry\:\:getWktCoord\(\) expects array\{x\: float\|int\|string, y\: float\|int\|string\}\|null, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
@ -6741,6 +6813,24 @@ parameters:
|
||||
count: 1
|
||||
path: src/Git.php
|
||||
|
||||
-
|
||||
message: '#^Offset 1 might not exist on array\{\}\|array\{0\: non\-falsy\-string, 1\: non\-empty\-string, 2\: non\-empty\-string, 3\: numeric\-string, 4\?\: non\-falsy\-string\}\.$#'
|
||||
identifier: offsetAccess.notFound
|
||||
count: 1
|
||||
path: src/Git.php
|
||||
|
||||
-
|
||||
message: '#^Offset 2 might not exist on array\{\}\|array\{0\: non\-falsy\-string, 1\: non\-empty\-string, 2\: non\-empty\-string, 3\: numeric\-string, 4\?\: non\-falsy\-string\}\.$#'
|
||||
identifier: offsetAccess.notFound
|
||||
count: 1
|
||||
path: src/Git.php
|
||||
|
||||
-
|
||||
message: '#^Offset 3 might not exist on array\{\}\|array\{0\: non\-falsy\-string, 1\: non\-empty\-string, 2\: non\-empty\-string, 3\: numeric\-string, 4\?\: non\-falsy\-string\}\.$#'
|
||||
identifier: offsetAccess.notFound
|
||||
count: 1
|
||||
path: src/Git.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in an if condition, string\|false given\.$#'
|
||||
identifier: if.condNotBoolean
|
||||
@ -7344,6 +7434,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/InsertEdit.php
|
||||
|
||||
-
|
||||
message: '#^Offset 2 might not exist on array\{\}\|array\{0\: non\-falsy\-string, 1\: string, 2\: string, 3\?\: numeric\-string\}\.$#'
|
||||
identifier: offsetAccess.notFound
|
||||
count: 1
|
||||
path: src/InsertEdit.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in &&, PhpMyAdmin\\Dbal\\ResultInterface\|false given on the left side\.$#'
|
||||
identifier: booleanAnd.leftNotBoolean
|
||||
@ -7369,7 +7465,7 @@ parameters:
|
||||
path: src/InsertEdit.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$currentRow of method PhpMyAdmin\\InsertEdit\:\:getDefaultValueAndBackupFieldForExistingRow\(\) expects array\<string\|null\>, array given\.$#'
|
||||
message: '#^Parameter \#1 \$currentRow of method PhpMyAdmin\\InsertEdit\:\:getDefaultValueAndBackupFieldForExistingRow\(\) expects array\<string\|null\>, array\<mixed\> given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/InsertEdit.php
|
||||
@ -8476,7 +8572,7 @@ parameters:
|
||||
path: src/Plugins/Auth/AuthenticationSignon.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$options of function session_set_cookie_params expects array\{lifetime\?\: int, path\?\: string\|null, domain\?\: string\|null, secure\?\: bool\|null, httponly\?\: bool\|null, samesite\?\: ''Lax''\|''lax''\|''None''\|''none''\|''Strict''\|''strict''\}, array given\.$#'
|
||||
message: '#^Parameter \#1 \$options of function session_set_cookie_params expects array\{lifetime\?\: int, path\?\: string\|null, domain\?\: string\|null, secure\?\: bool\|null, httponly\?\: bool\|null, samesite\?\: ''Lax''\|''lax''\|''None''\|''none''\|''Strict''\|''strict''\}, array\<mixed\> given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Plugins/Auth/AuthenticationSignon.php
|
||||
@ -8500,7 +8596,7 @@ parameters:
|
||||
path: src/Plugins/Auth/AuthenticationSignon.php
|
||||
|
||||
-
|
||||
message: '#^Property PhpMyAdmin\\Config\:\:\$selectedServer \(array\{host\: string, port\: string, socket\: string, ssl\: bool, ssl_key\: string\|null, ssl_cert\: string\|null, ssl_ca\: string\|null, ssl_ca_path\: string\|null, \.\.\.\}\) does not accept non\-empty\-array\.$#'
|
||||
message: '#^Property PhpMyAdmin\\Config\:\:\$selectedServer \(array\{host\: string, port\: string, socket\: string, ssl\: bool, ssl_key\: string\|null, ssl_cert\: string\|null, ssl_ca\: string\|null, ssl_ca_path\: string\|null, \.\.\.\}\) does not accept non\-empty\-array\<mixed, mixed\>\.$#'
|
||||
identifier: assign.propertyType
|
||||
count: 1
|
||||
path: src/Plugins/Auth/AuthenticationSignon.php
|
||||
@ -9366,6 +9462,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/Plugins/Import/ImportSql.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$sqlCompatibility of method PhpMyAdmin\\Plugins\\Import\\ImportSql\:\:setSQLMode\(\) expects string\|null, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Plugins/Import/ImportSql.php
|
||||
|
||||
-
|
||||
message: '#^Argument of an invalid type SimpleXMLElement\|null supplied for foreach, only iterables are supported\.$#'
|
||||
identifier: foreach.nonIterable
|
||||
@ -9582,6 +9684,12 @@ parameters:
|
||||
count: 2
|
||||
path: src/Plugins/Import/Upload/UploadSession.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in an if condition, mixed given\.$#'
|
||||
identifier: if.condNotBoolean
|
||||
count: 1
|
||||
path: src/Plugins/Import/Upload/UploadSession.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in \|\|, mixed given on the right side\.$#'
|
||||
identifier: booleanOr.rightNotBoolean
|
||||
@ -10329,6 +10437,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/Plugins/Transformations/Abs/TextLinkTransformationsPlugin.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in &&, mixed given on the right side\.$#'
|
||||
identifier: booleanAnd.rightNotBoolean
|
||||
count: 1
|
||||
path: src/Plugins/Transformations/Abs/TextLinkTransformationsPlugin.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$string of function htmlspecialchars expects string, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
@ -10540,7 +10654,7 @@ parameters:
|
||||
path: src/Query/Compatibility.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$string of function strtoupper expects string, \(int\|string\) given\.$#'
|
||||
message: '#^Parameter \#1 \$string of function strtoupper expects string, int\|string given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Query/Compatibility.php
|
||||
@ -10992,12 +11106,6 @@ parameters:
|
||||
count: 1
|
||||
path: src/Server/Privileges.php
|
||||
|
||||
-
|
||||
message: '#^Cannot access offset 0 on mixed\.$#'
|
||||
identifier: offsetAccess.nonOffsetAccessible
|
||||
count: 2
|
||||
path: src/Server/Privileges.php
|
||||
|
||||
-
|
||||
message: '#^Cannot cast array\<string\>\|string\|null to string\.$#'
|
||||
identifier: cast.string
|
||||
@ -11136,18 +11244,6 @@ parameters:
|
||||
count: 1
|
||||
path: src/Server/Privileges.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$query of method PhpMyAdmin\\Dbal\\DatabaseInterface\:\:query\(\) expects string, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Server/Privileges.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$query of method PhpMyAdmin\\Dbal\\DatabaseInterface\:\:tryQuery\(\) expects string, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Server/Privileges.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$row of method PhpMyAdmin\\Server\\Privileges\:\:extractPrivInfo\(\) expects array\<mixed\>\|null, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
@ -11334,7 +11430,7 @@ parameters:
|
||||
-
|
||||
message: '#^Only booleans are allowed in an if condition, mixed given\.$#'
|
||||
identifier: if.condNotBoolean
|
||||
count: 2
|
||||
count: 1
|
||||
path: src/Server/Status/Data.php
|
||||
|
||||
-
|
||||
@ -11445,6 +11541,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/Server/Status/Monitor.php
|
||||
|
||||
-
|
||||
message: '#^Offset 1 might not exist on array\{\}\|array\{non\-falsy\-string, non\-empty\-string\}\.$#'
|
||||
identifier: offsetAccess.notFound
|
||||
count: 1
|
||||
path: src/Server/Status/Monitor.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in a negated boolean, mixed given\.$#'
|
||||
identifier: booleanNot.exprNotBoolean
|
||||
@ -11592,7 +11694,7 @@ parameters:
|
||||
-
|
||||
message: '#^Method PhpMyAdmin\\Setup\\ConfigGenerator\:\:getBlowfishSecretKey\(\) should return non\-empty\-string but returns string\.$#'
|
||||
identifier: return.type
|
||||
count: 2
|
||||
count: 1
|
||||
path: src/Setup/ConfigGenerator.php
|
||||
|
||||
-
|
||||
@ -12228,6 +12330,12 @@ parameters:
|
||||
count: 3
|
||||
path: src/Table/Search.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#2 \$array of function implode expects array\<string\>, array\<mixed\> given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Table/Search.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#2 \$names of method PhpMyAdmin\\Table\\Search\:\:getWhereClause\(\) expects string, mixed given\.$#'
|
||||
identifier: argument.type
|
||||
@ -12373,7 +12481,7 @@ parameters:
|
||||
path: src/Table/Table.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$callback of function array_map expects \(callable\(mixed\)\: mixed\)\|null, Closure\(array\|bool\|float\|int\|resource\|string\|null, int\=\)\: int given\.$#'
|
||||
message: '#^Parameter \#1 \$callback of function array_map expects \(callable\(mixed\)\: mixed\)\|null, Closure\(array\|bool\|float\|GMP\|int\|resource\|SimpleXMLElement\|string\|null, int\=\)\: int given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Table/Table.php
|
||||
@ -13038,6 +13146,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/Util.php
|
||||
|
||||
-
|
||||
message: '#^Offset 1 might not exist on array\{\}\|array\{non\-falsy\-string, string\}\.$#'
|
||||
identifier: offsetAccess.notFound
|
||||
count: 1
|
||||
path: src/Util.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in a negated boolean, int\<0, 2\> given\.$#'
|
||||
identifier: booleanNot.exprNotBoolean
|
||||
@ -13086,6 +13200,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/Util.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#2 \$array of function implode expects array\<string\>, list given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/Util.php
|
||||
|
||||
-
|
||||
message: '#^Variable static method call on PhpMyAdmin\\Util\.$#'
|
||||
identifier: staticMethod.dynamicName
|
||||
@ -13188,6 +13308,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/Utils/HttpRequest.php
|
||||
|
||||
-
|
||||
message: '#^Offset 1 might not exist on array\{\}\|array\{non\-falsy\-string, numeric\-string\}\.$#'
|
||||
identifier: offsetAccess.notFound
|
||||
count: 1
|
||||
path: src/Utils/HttpRequest.php
|
||||
|
||||
-
|
||||
message: '#^Only booleans are allowed in an if condition, string\|false given\.$#'
|
||||
identifier: if.condNotBoolean
|
||||
@ -13428,6 +13554,12 @@ parameters:
|
||||
count: 1
|
||||
path: src/WebAuthn/WebauthnLibServer.php
|
||||
|
||||
-
|
||||
message: '#^Call to function is_array\(\) with array\<string\> will always evaluate to true\.$#'
|
||||
identifier: function.alreadyNarrowedType
|
||||
count: 1
|
||||
path: src/ZipExtension.php
|
||||
|
||||
-
|
||||
message: '#^Method PhpMyAdmin\\ZipExtension\:\:getContents\(\) should return array\{error\: string, data\: string\} but returns array\{error\: '''', data\: string\|false\}\.$#'
|
||||
identifier: return.type
|
||||
@ -13440,18 +13572,6 @@ parameters:
|
||||
count: 1
|
||||
path: src/ZipExtension.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#1 \$keys of function array_combine expects array\<int\|string\>, array\<mixed, mixed\> given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/ZipExtension.php
|
||||
|
||||
-
|
||||
message: '#^Parameter \#3 \$subject of function str_replace expects array\<string\>\|string, \(int\|string\) given\.$#'
|
||||
identifier: argument.type
|
||||
count: 1
|
||||
path: src/ZipExtension.php
|
||||
|
||||
-
|
||||
message: '#^Cannot access offset ''Console'' on mixed\.$#'
|
||||
identifier: offsetAccess.nonOffsetAccessible
|
||||
@ -13932,6 +14052,12 @@ parameters:
|
||||
count: 1
|
||||
path: tests/unit/Config/FormDisplayTest.php
|
||||
|
||||
-
|
||||
message: '#^Offset 1 might not exist on array\{\}\|array\{non\-falsy\-string, numeric\-string\}\.$#'
|
||||
identifier: offsetAccess.notFound
|
||||
count: 1
|
||||
path: tests/unit/Config/FormTest.php
|
||||
|
||||
-
|
||||
message: '''
|
||||
#^Call to deprecated method getInstance\(\) of class PhpMyAdmin\\Config\:
|
||||
@ -16594,7 +16720,7 @@ parameters:
|
||||
path: tests/unit/Table/TableTest.php
|
||||
|
||||
-
|
||||
message: '#^Offset ''col_order'' on non\-empty\-array in isset\(\) always exists and is not nullable\.$#'
|
||||
message: '#^Offset ''col_order'' on non\-empty\-array\<mixed\> in isset\(\) always exists and is not nullable\.$#'
|
||||
identifier: isset.offset
|
||||
count: 1
|
||||
path: tests/unit/Table/TableTest.php
|
||||
|
||||
@ -1589,9 +1589,6 @@
|
||||
<MixedArgument>
|
||||
<code><![CDATA[$database['DEFAULT_COLLATION_NAME']]]></code>
|
||||
<code><![CDATA[$database['SCHEMA_NAME']]]></code>
|
||||
<code><![CDATA[$primaryInfo['Do_DB']]]></code>
|
||||
<code><![CDATA[$primaryInfo['Do_DB']]]></code>
|
||||
<code><![CDATA[$primaryInfo['Ignore_DB']]]></code>
|
||||
<code><![CDATA[$replicaInfo['Do_DB']]]></code>
|
||||
<code><![CDATA[$replicaInfo['Do_DB']]]></code>
|
||||
<code><![CDATA[$replicaInfo['Ignore_DB']]]></code>
|
||||
@ -1622,9 +1619,11 @@
|
||||
<code><![CDATA[$database]]></code>
|
||||
<code><![CDATA[$key]]></code>
|
||||
<code><![CDATA[$key]]></code>
|
||||
<code><![CDATA[$key]]></code>
|
||||
<code><![CDATA[$key]]></code>
|
||||
</MixedAssignment>
|
||||
<PossiblyUndefinedArrayOffset>
|
||||
<code><![CDATA[$primaryInfo['Do_DB']]]></code>
|
||||
<code><![CDATA[$primaryInfo['Ignore_DB']]]></code>
|
||||
</PossiblyUndefinedArrayOffset>
|
||||
<PossiblyUnusedReturnValue>
|
||||
<code><![CDATA[Response]]></code>
|
||||
</PossiblyUnusedReturnValue>
|
||||
@ -1675,9 +1674,6 @@
|
||||
<code><![CDATA[$urlDbname ?? '']]></code>
|
||||
<code><![CDATA[$urlDbname ?? '']]></code>
|
||||
</MixedArgument>
|
||||
<MixedArgumentTypeCoercion>
|
||||
<code><![CDATA[$queries]]></code>
|
||||
</MixedArgumentTypeCoercion>
|
||||
<RiskyTruthyFalsyComparison>
|
||||
<code><![CDATA[empty($_REQUEST['ajax_page_request'])]]></code>
|
||||
</RiskyTruthyFalsyComparison>
|
||||
@ -6284,14 +6280,9 @@
|
||||
</PossiblyUnusedReturnValue>
|
||||
</file>
|
||||
<file src="src/Plugins/Import/ImportSql.php">
|
||||
<MixedArgumentTypeCoercion>
|
||||
<code><![CDATA[$sqlModes]]></code>
|
||||
</MixedArgumentTypeCoercion>
|
||||
<MixedAssignment>
|
||||
<code><![CDATA[$sqlModes[]]]></code>
|
||||
</MixedAssignment>
|
||||
<PossiblyInvalidArgument>
|
||||
<code><![CDATA[$_POST['sql_delimiter']]]></code>
|
||||
<code><![CDATA[$_REQUEST['sql_compatibility'] ?? null]]></code>
|
||||
</PossiblyInvalidArgument>
|
||||
<PossiblyInvalidCast>
|
||||
<code><![CDATA[$_POST['sql_delimiter']]]></code>
|
||||
@ -7272,12 +7263,7 @@
|
||||
<code><![CDATA[$row['Proc_priv']]]></code>
|
||||
<code><![CDATA[$row['Table_priv']]]></code>
|
||||
<code><![CDATA[$row['Table_priv']]]></code>
|
||||
<code><![CDATA[$sqlQuery]]></code>
|
||||
<code><![CDATA[$sqlQuery]]></code>
|
||||
</MixedArgument>
|
||||
<MixedArgumentTypeCoercion>
|
||||
<code><![CDATA[$queries]]></code>
|
||||
</MixedArgumentTypeCoercion>
|
||||
<MixedArrayAccess>
|
||||
<code><![CDATA[$groupAssignment[$host['User']]]]></code>
|
||||
<code><![CDATA[$row['Db']]]></code>
|
||||
@ -7288,8 +7274,6 @@
|
||||
<code><![CDATA[$row['Routine_name']]]></code>
|
||||
<code><![CDATA[$row['Table_name']]]></code>
|
||||
<code><![CDATA[$row['Table_priv']]]></code>
|
||||
<code><![CDATA[$sqlQuery[0]]]></code>
|
||||
<code><![CDATA[$sqlQuery[0]]]></code>
|
||||
</MixedArrayAccess>
|
||||
<MixedAssignment>
|
||||
<code><![CDATA[$extraData['db_wildcard_privs']]]></code>
|
||||
@ -7302,10 +7286,7 @@
|
||||
<code><![CDATA[$paramDbName]]></code>
|
||||
<code><![CDATA[$paramRoutineName]]></code>
|
||||
<code><![CDATA[$paramTableName]]></code>
|
||||
<code><![CDATA[$queries[$tmpCount]]]></code>
|
||||
<code><![CDATA[$row]]></code>
|
||||
<code><![CDATA[$sqlQuery]]></code>
|
||||
<code><![CDATA[$sqlQuery]]></code>
|
||||
</MixedAssignment>
|
||||
<MixedOperand>
|
||||
<code><![CDATA[$origValue]]></code>
|
||||
@ -8605,18 +8586,6 @@
|
||||
<code><![CDATA[$regex]]></code>
|
||||
<code><![CDATA[$specificEntry]]></code>
|
||||
</ArgumentTypeCoercion>
|
||||
<MixedArgumentTypeCoercion>
|
||||
<code><![CDATA[$name]]></code>
|
||||
<code><![CDATA[$table]]></code>
|
||||
</MixedArgumentTypeCoercion>
|
||||
<PossiblyInvalidArgument>
|
||||
<code><![CDATA[$tempName]]></code>
|
||||
<code><![CDATA[$tempName]]></code>
|
||||
</PossiblyInvalidArgument>
|
||||
<PossiblyInvalidOperand>
|
||||
<code><![CDATA[$tempName]]></code>
|
||||
<code><![CDATA[$tempName]]></code>
|
||||
</PossiblyInvalidOperand>
|
||||
</file>
|
||||
<file src="tests/end-to-end/TestBase.php">
|
||||
<DeprecatedConstant>
|
||||
|
||||
@ -174,8 +174,8 @@ final class DatabasesController implements InvocableController
|
||||
}
|
||||
|
||||
/**
|
||||
* @param mixed[] $primaryInfo
|
||||
* @param mixed[] $replicaInfo
|
||||
* @param array{status: bool, Do_DB?: string[], Ignore_DB?: string[]} $primaryInfo
|
||||
* @param mixed[] $replicaInfo
|
||||
*
|
||||
* @return array{databases:mixed[], total_statistics:mixed[]}
|
||||
*/
|
||||
|
||||
@ -95,7 +95,7 @@ class ImportSql extends ImportPlugin
|
||||
public function doImport(File|null $importHandle = null): array
|
||||
{
|
||||
// Handle compatibility options.
|
||||
$this->setSQLMode($_REQUEST);
|
||||
$this->setSQLMode($_REQUEST['sql_compatibility'] ?? null, isset($_REQUEST['sql_no_auto_value_on_zero']));
|
||||
|
||||
$bq = new BufferedQuery();
|
||||
if (isset($_POST['sql_delimiter'])) {
|
||||
@ -164,19 +164,14 @@ class ImportSql extends ImportPlugin
|
||||
return $sqlStatements;
|
||||
}
|
||||
|
||||
/**
|
||||
* Handle compatibility options
|
||||
*
|
||||
* @param mixed[] $request Request array
|
||||
*/
|
||||
private function setSQLMode(array $request): void
|
||||
private function setSQLMode(string|null $sqlCompatibility, bool $sqlNoAutoValueOnZero): void
|
||||
{
|
||||
$sqlModes = [];
|
||||
if (isset($request['sql_compatibility']) && $request['sql_compatibility'] !== 'NONE') {
|
||||
$sqlModes[] = $request['sql_compatibility'];
|
||||
if ($sqlCompatibility !== null && $sqlCompatibility !== 'NONE') {
|
||||
$sqlModes[] = $sqlCompatibility;
|
||||
}
|
||||
|
||||
if (isset($request['sql_no_auto_value_on_zero'])) {
|
||||
if ($sqlNoAutoValueOnZero) {
|
||||
$sqlModes[] = 'NO_AUTO_VALUE_ON_ZERO';
|
||||
}
|
||||
|
||||
|
||||
@ -79,8 +79,8 @@ final class ReplicationInfo
|
||||
/** @var mixed[] */
|
||||
private array $multiPrimaryStatus = [];
|
||||
|
||||
/** @var mixed[] */
|
||||
private array $primaryInfo = [];
|
||||
/** @var array{status: bool, Do_DB?: string[], Ignore_DB?: string[]} */
|
||||
private array $primaryInfo = ['status' => false];
|
||||
|
||||
/** @var mixed[] */
|
||||
private array $replicaInfo = [];
|
||||
@ -177,7 +177,7 @@ final class ReplicationInfo
|
||||
$this->primaryInfo['Ignore_DB'] = $this->fill($this->primaryStatus, 'Binlog_Ignore_DB');
|
||||
}
|
||||
|
||||
/** @return mixed[] */
|
||||
/** @return array{status: bool, Do_DB?: string[], Ignore_DB?: string[]} */
|
||||
public function getPrimaryInfo(): array
|
||||
{
|
||||
return $this->primaryInfo;
|
||||
|
||||
@ -1869,7 +1869,7 @@ class Privileges
|
||||
/**
|
||||
* Delete user and get message and sql query for delete user in privileges
|
||||
*
|
||||
* @param mixed[] $queries queries
|
||||
* @param string[] $queries queries
|
||||
*
|
||||
* @return array{string, Message} Message
|
||||
*/
|
||||
@ -2106,9 +2106,9 @@ class Privileges
|
||||
/**
|
||||
* Update Data for information: Deletes users
|
||||
*
|
||||
* @param mixed[] $queries queries array
|
||||
* @param string[] $queries queries array
|
||||
*
|
||||
* @return mixed[]
|
||||
* @return string[]
|
||||
*/
|
||||
public function getDataForDeleteUsers(array $queries, bool $isChangeCopyUser): array
|
||||
{
|
||||
@ -2173,10 +2173,10 @@ class Privileges
|
||||
/**
|
||||
* update Data For Queries from queries_for_display
|
||||
*
|
||||
* @param mixed[] $queries queries array
|
||||
* @param mixed[]|null $queriesForDisplay queries array for display
|
||||
* @param string[] $queries queries array
|
||||
* @param string[]|null $queriesForDisplay queries array for display
|
||||
*
|
||||
* @return mixed[]
|
||||
* @return string[]
|
||||
*/
|
||||
public function getDataForQueries(array $queries, array|null $queriesForDisplay): array
|
||||
{
|
||||
@ -2626,12 +2626,12 @@ class Privileges
|
||||
/**
|
||||
* Get queries for Table privileges to change or copy user
|
||||
*
|
||||
* @param string $userHostCondition user host condition to select relevant table privileges
|
||||
* @param mixed[] $queries queries array
|
||||
* @param string $username username
|
||||
* @param string $hostname host name
|
||||
* @param string $userHostCondition user host condition to select relevant table privileges
|
||||
* @param string[] $queries queries array
|
||||
* @param string $username username
|
||||
* @param string $hostname host name
|
||||
*
|
||||
* @return mixed[]
|
||||
* @return string[]
|
||||
*/
|
||||
public function getTablePrivsQueriesForChangeOrCopyUser(
|
||||
string $userHostCondition,
|
||||
@ -2708,11 +2708,11 @@ class Privileges
|
||||
/**
|
||||
* Get queries for database specific privileges for change or copy user
|
||||
*
|
||||
* @param mixed[] $queries queries array with string
|
||||
* @param string $username username
|
||||
* @param string $hostname host name
|
||||
* @param string[] $queries queries array with string
|
||||
* @param string $username username
|
||||
* @param string $hostname host name
|
||||
*
|
||||
* @return mixed[]
|
||||
* @return string[]
|
||||
*/
|
||||
public function getDbSpecificPrivsQueriesForChangeOrCopyUser(
|
||||
array $queries,
|
||||
|
||||
@ -195,7 +195,7 @@ class ZipExtension
|
||||
* same amount of elements.
|
||||
*
|
||||
* @param string[]|string $data contents of the file/files
|
||||
* @param mixed[]|string $name name of the file/files in the archive
|
||||
* @param string[]|string $name name of the file/files in the archive
|
||||
*
|
||||
* @return string|false the ZIP file contents, or false if there was an error.
|
||||
*/
|
||||
|
||||
Loading…
Reference in New Issue
Block a user