Skip to content

Commit 8dce3ac

Browse files
Merge pull request #19652 from MauricioFauth/indexes
Move indexes classes to the Indexes namespace
2 parents 8d91387 + c52edb3 commit 8dce3ac

28 files changed

Lines changed: 80 additions & 75 deletions

phpstan-baseline.neon

Lines changed: 46 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -3934,7 +3934,7 @@ parameters:
39343934
path: src/Controllers/Table/RelationController.php
39353935

39363936
-
3937-
message: '#^Parameter \#2 \$table of static method PhpMyAdmin\\Index\:\:getPrimary\(\) expects string, mixed given\.$#'
3937+
message: '#^Parameter \#2 \$table of static method PhpMyAdmin\\Indexes\\Index\:\:getPrimary\(\) expects string, mixed given\.$#'
39383938
identifier: argument.type
39393939
count: 1
39403940
path: src/Controllers/Table/RelationController.php
@@ -3958,7 +3958,7 @@ parameters:
39583958
path: src/Controllers/Table/RelationController.php
39593959

39603960
-
3961-
message: '#^Parameter \#3 \$schema of static method PhpMyAdmin\\Index\:\:getPrimary\(\) expects string, mixed given\.$#'
3961+
message: '#^Parameter \#3 \$schema of static method PhpMyAdmin\\Indexes\\Index\:\:getPrimary\(\) expects string, mixed given\.$#'
39623962
identifier: argument.type
39633963
count: 1
39643964
path: src/Controllers/Table/RelationController.php
@@ -8569,7 +8569,7 @@ parameters:
85698569
message: '#^Argument of an invalid type mixed supplied for foreach, only iterables are supported\.$#'
85708570
identifier: foreach.nonIterable
85718571
count: 1
8572-
path: src/Index.php
8572+
path: src/Indexes/Index.php
85738573

85748574
-
85758575
message: '''
@@ -8578,139 +8578,139 @@ parameters:
85788578
'''
85798579
identifier: staticMethod.deprecated
85808580
count: 3
8581-
path: src/Index.php
8581+
path: src/Indexes/Index.php
85828582

85838583
-
85848584
message: '#^Cannot access offset mixed on mixed\.$#'
85858585
identifier: offsetAccess.nonOffsetAccessible
85868586
count: 1
8587-
path: src/Index.php
8587+
path: src/Indexes/Index.php
85888588

85898589
-
85908590
message: '#^Cannot cast mixed to int\.$#'
85918591
identifier: cast.int
85928592
count: 1
8593-
path: src/Index.php
8593+
path: src/Indexes/Index.php
85948594

85958595
-
85968596
message: '#^Only booleans are allowed in &&, int\<0, 1\> given on the left side\.$#'
85978597
identifier: booleanAnd.leftNotBoolean
85988598
count: 1
8599-
path: src/Index.php
8599+
path: src/Indexes/Index.php
86008600

86018601
-
86028602
message: '#^Only booleans are allowed in &&, int\<0, 2\> given on the left side\.$#'
86038603
identifier: booleanAnd.leftNotBoolean
86048604
count: 1
8605-
path: src/Index.php
8605+
path: src/Indexes/Index.php
86068606

86078607
-
86088608
message: '#^Only booleans are allowed in &&, int\<0, 4\> given on the left side\.$#'
86098609
identifier: booleanAnd.leftNotBoolean
86108610
count: 1
8611-
path: src/Index.php
8611+
path: src/Indexes/Index.php
86128612

86138613
-
86148614
message: '#^Only booleans are allowed in &&, int\<0, 8\> given on the left side\.$#'
86158615
identifier: booleanAnd.leftNotBoolean
86168616
count: 1
8617-
path: src/Index.php
8617+
path: src/Indexes/Index.php
86188618

86198619
-
8620-
message: '#^Parameter \#1 \$columns of method PhpMyAdmin\\Index\:\:addColumns\(\) expects array\<mixed\>, mixed given\.$#'
8620+
message: '#^Parameter \#1 \$columns of method PhpMyAdmin\\Indexes\\Index\:\:addColumns\(\) expects array\<mixed\>, mixed given\.$#'
86218621
identifier: argument.type
86228622
count: 1
8623-
path: src/Index.php
8623+
path: src/Indexes/Index.php
86248624

86258625
-
8626-
message: '#^Parameter \#1 \$params of method PhpMyAdmin\\Index\:\:addColumn\(\) expects array\<string, string\|null\>, mixed given\.$#'
8626+
message: '#^Parameter \#1 \$params of method PhpMyAdmin\\Indexes\\Index\:\:addColumn\(\) expects array\<string, string\|null\>, mixed given\.$#'
86278627
identifier: argument.type
86288628
count: 1
8629-
path: src/Index.php
8629+
path: src/Indexes/Index.php
86308630

86318631
-
8632-
message: '#^Property PhpMyAdmin\\Index\:\:\$choice \(string\) does not accept mixed\.$#'
8632+
message: '#^Property PhpMyAdmin\\Indexes\\Index\:\:\$choice \(string\) does not accept mixed\.$#'
86338633
identifier: assign.propertyType
86348634
count: 1
8635-
path: src/Index.php
8635+
path: src/Indexes/Index.php
86368636

86378637
-
8638-
message: '#^Property PhpMyAdmin\\Index\:\:\$comment \(string\) does not accept mixed\.$#'
8638+
message: '#^Property PhpMyAdmin\\Indexes\\Index\:\:\$comment \(string\) does not accept mixed\.$#'
86398639
identifier: assign.propertyType
86408640
count: 1
8641-
path: src/Index.php
8641+
path: src/Indexes/Index.php
86428642

86438643
-
8644-
message: '#^Property PhpMyAdmin\\Index\:\:\$name \(string\) does not accept mixed\.$#'
8644+
message: '#^Property PhpMyAdmin\\Indexes\\Index\:\:\$name \(string\) does not accept mixed\.$#'
86458645
identifier: assign.propertyType
86468646
count: 1
8647-
path: src/Index.php
8647+
path: src/Indexes/Index.php
86488648

86498649
-
8650-
message: '#^Property PhpMyAdmin\\Index\:\:\$packed \(string\|null\) does not accept mixed\.$#'
8650+
message: '#^Property PhpMyAdmin\\Indexes\\Index\:\:\$packed \(string\|null\) does not accept mixed\.$#'
86518651
identifier: assign.propertyType
86528652
count: 1
8653-
path: src/Index.php
8653+
path: src/Indexes/Index.php
86548654

86558655
-
8656-
message: '#^Property PhpMyAdmin\\Index\:\:\$parser \(string\) does not accept mixed\.$#'
8656+
message: '#^Property PhpMyAdmin\\Indexes\\Index\:\:\$parser \(string\) does not accept mixed\.$#'
86578657
identifier: assign.propertyType
86588658
count: 1
8659-
path: src/Index.php
8659+
path: src/Indexes/Index.php
86608660

86618661
-
8662-
message: '#^Property PhpMyAdmin\\Index\:\:\$remarks \(string\) does not accept mixed\.$#'
8662+
message: '#^Property PhpMyAdmin\\Indexes\\Index\:\:\$remarks \(string\) does not accept mixed\.$#'
86638663
identifier: assign.propertyType
86648664
count: 1
8665-
path: src/Index.php
8665+
path: src/Indexes/Index.php
86668666

86678667
-
8668-
message: '#^Property PhpMyAdmin\\Index\:\:\$schema \(string\) does not accept mixed\.$#'
8668+
message: '#^Property PhpMyAdmin\\Indexes\\Index\:\:\$schema \(string\) does not accept mixed\.$#'
86698669
identifier: assign.propertyType
86708670
count: 1
8671-
path: src/Index.php
8671+
path: src/Indexes/Index.php
86728672

86738673
-
8674-
message: '#^Property PhpMyAdmin\\Index\:\:\$table \(string\) does not accept mixed\.$#'
8674+
message: '#^Property PhpMyAdmin\\Indexes\\Index\:\:\$table \(string\) does not accept mixed\.$#'
86758675
identifier: assign.propertyType
86768676
count: 1
8677-
path: src/Index.php
8677+
path: src/Indexes/Index.php
86788678

86798679
-
8680-
message: '#^Property PhpMyAdmin\\Index\:\:\$type \(string\) does not accept mixed\.$#'
8680+
message: '#^Property PhpMyAdmin\\Indexes\\Index\:\:\$type \(string\) does not accept mixed\.$#'
86818681
identifier: assign.propertyType
86828682
count: 1
8683-
path: src/Index.php
8683+
path: src/Indexes/Index.php
86848684

86858685
-
86868686
message: '#^Cannot cast mixed to int\.$#'
86878687
identifier: cast.int
86888688
count: 3
8689-
path: src/IndexColumn.php
8689+
path: src/Indexes/IndexColumn.php
86908690

86918691
-
8692-
message: '#^Property PhpMyAdmin\\IndexColumn\:\:\$collation \(string\|null\) does not accept mixed\.$#'
8692+
message: '#^Property PhpMyAdmin\\Indexes\\IndexColumn\:\:\$collation \(string\|null\) does not accept mixed\.$#'
86938693
identifier: assign.propertyType
86948694
count: 1
8695-
path: src/IndexColumn.php
8695+
path: src/Indexes/IndexColumn.php
86968696

86978697
-
8698-
message: '#^Property PhpMyAdmin\\IndexColumn\:\:\$expression \(string\|null\) does not accept mixed\.$#'
8698+
message: '#^Property PhpMyAdmin\\Indexes\\IndexColumn\:\:\$expression \(string\|null\) does not accept mixed\.$#'
86998699
identifier: assign.propertyType
87008700
count: 1
8701-
path: src/IndexColumn.php
8701+
path: src/Indexes/IndexColumn.php
87028702

87038703
-
8704-
message: '#^Property PhpMyAdmin\\IndexColumn\:\:\$name \(string\) does not accept mixed\.$#'
8704+
message: '#^Property PhpMyAdmin\\Indexes\\IndexColumn\:\:\$name \(string\) does not accept mixed\.$#'
87058705
identifier: assign.propertyType
87068706
count: 1
8707-
path: src/IndexColumn.php
8707+
path: src/Indexes/IndexColumn.php
87088708

87098709
-
8710-
message: '#^Property PhpMyAdmin\\IndexColumn\:\:\$null \(string\) does not accept mixed\.$#'
8710+
message: '#^Property PhpMyAdmin\\Indexes\\IndexColumn\:\:\$null \(string\) does not accept mixed\.$#'
87118711
identifier: assign.propertyType
87128712
count: 1
8713-
path: src/IndexColumn.php
8713+
path: src/Indexes/IndexColumn.php
87148714

87158715
-
87168716
message: '#^Binary operation "\." between non\-falsy\-string and mixed results in an error\.$#'
@@ -9547,13 +9547,13 @@ parameters:
95479547
path: src/Normalization.php
95489548

95499549
-
9550-
message: '#^Parameter \#2 \$table of static method PhpMyAdmin\\Index\:\:getPrimary\(\) expects string, \(int\|string\) given\.$#'
9550+
message: '#^Parameter \#2 \$table of static method PhpMyAdmin\\Indexes\\Index\:\:getPrimary\(\) expects string, \(int\|string\) given\.$#'
95519551
identifier: argument.type
95529552
count: 1
95539553
path: src/Normalization.php
95549554

95559555
-
9556-
message: '#^Parameter \#2 \$table of static method PhpMyAdmin\\Index\:\:getPrimary\(\) expects string, mixed given\.$#'
9556+
message: '#^Parameter \#2 \$table of static method PhpMyAdmin\\Indexes\\Index\:\:getPrimary\(\) expects string, mixed given\.$#'
95579557
identifier: argument.type
95589558
count: 1
95599559
path: src/Normalization.php
@@ -18991,13 +18991,13 @@ parameters:
1899118991
message: '#^Cannot access an offset on mixed\.$#'
1899218992
identifier: offsetAccess.nonOffsetAccessible
1899318993
count: 3
18994-
path: tests/unit/IndexTest.php
18994+
path: tests/unit/Indexes/IndexTest.php
1899518995

1899618996
-
18997-
message: '#^Parameter \#1 \$columns of method PhpMyAdmin\\Index\:\:addColumns\(\) expects array\<mixed\>, mixed given\.$#'
18997+
message: '#^Parameter \#1 \$columns of method PhpMyAdmin\\Indexes\\Index\:\:addColumns\(\) expects array\<mixed\>, mixed given\.$#'
1899818998
identifier: argument.type
1899918999
count: 2
19000-
path: tests/unit/IndexTest.php
19000+
path: tests/unit/Indexes/IndexTest.php
1900119001

1900219002
-
1900319003
message: '''

psalm-baseline.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5258,7 +5258,7 @@
52585258
<code><![CDATA[ImportSettings::$runQuery]]></code>
52595259
</RiskyTruthyFalsyComparison>
52605260
</file>
5261-
<file src="src/Index.php">
5261+
<file src="src/Indexes/Index.php">
52625262
<DeprecatedMethod>
52635263
<code><![CDATA[DatabaseInterface::getInstance()]]></code>
52645264
<code><![CDATA[DatabaseInterface::getInstance()]]></code>
@@ -5294,7 +5294,7 @@
52945294
<code><![CDATA[isPacked]]></code>
52955295
</PossiblyUnusedMethod>
52965296
</file>
5297-
<file src="src/IndexColumn.php">
5297+
<file src="src/Indexes/IndexColumn.php">
52985298
<MixedAssignment>
52995299
<code><![CDATA[$this->collation]]></code>
53005300
<code><![CDATA[$this->expression]]></code>
@@ -11546,7 +11546,7 @@
1154611546
<code><![CDATA[providerContentWithByteOrderMarks]]></code>
1154711547
</PossiblyUnusedMethod>
1154811548
</file>
11549-
<file src="tests/unit/IndexTest.php">
11549+
<file src="tests/unit/Indexes/IndexTest.php">
1155011550
<MixedArgument>
1155111551
<code><![CDATA[$this->params['columns']]]></code>
1155211552
<code><![CDATA[$this->params['columns']]]></code>

src/Controllers/Database/DataDictionaryController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
use PhpMyAdmin\Dbal\DatabaseInterface;
1111
use PhpMyAdmin\Http\Response;
1212
use PhpMyAdmin\Http\ServerRequest;
13-
use PhpMyAdmin\Index;
13+
use PhpMyAdmin\Indexes\Index;
1414
use PhpMyAdmin\ResponseRenderer;
1515
use PhpMyAdmin\Transformations;
1616
use PhpMyAdmin\Util;

src/Controllers/Operations/TableController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
use PhpMyAdmin\Http\ServerRequest;
1717
use PhpMyAdmin\Identifiers\DatabaseName;
1818
use PhpMyAdmin\Identifiers\TableName;
19-
use PhpMyAdmin\Index;
19+
use PhpMyAdmin\Indexes\Index;
2020
use PhpMyAdmin\Message;
2121
use PhpMyAdmin\MessageType;
2222
use PhpMyAdmin\Operations;

src/Controllers/Table/IndexRenameController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
use PhpMyAdmin\Http\ServerRequest;
1414
use PhpMyAdmin\Identifiers\DatabaseName;
1515
use PhpMyAdmin\Identifiers\TableName;
16-
use PhpMyAdmin\Index;
16+
use PhpMyAdmin\Indexes\Index;
1717
use PhpMyAdmin\Message;
1818
use PhpMyAdmin\MessageType;
1919
use PhpMyAdmin\ResponseRenderer;

src/Controllers/Table/IndexesController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
use PhpMyAdmin\Http\ServerRequest;
1616
use PhpMyAdmin\Identifiers\DatabaseName;
1717
use PhpMyAdmin\Identifiers\TableName;
18-
use PhpMyAdmin\Index;
18+
use PhpMyAdmin\Indexes\Index;
1919
use PhpMyAdmin\Message;
2020
use PhpMyAdmin\MessageType;
2121
use PhpMyAdmin\ResponseRenderer;

src/Controllers/Table/RelationController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
use PhpMyAdmin\Html\Generator;
1616
use PhpMyAdmin\Http\Response;
1717
use PhpMyAdmin\Http\ServerRequest;
18-
use PhpMyAdmin\Index;
18+
use PhpMyAdmin\Indexes\Index;
1919
use PhpMyAdmin\MessageType;
2020
use PhpMyAdmin\ResponseRenderer;
2121
use PhpMyAdmin\Table\Table;

src/Controllers/Table/Structure/SaveController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
use PhpMyAdmin\Html\Generator;
1515
use PhpMyAdmin\Http\Response;
1616
use PhpMyAdmin\Http\ServerRequest;
17-
use PhpMyAdmin\Index;
17+
use PhpMyAdmin\Indexes\Index;
1818
use PhpMyAdmin\Message;
1919
use PhpMyAdmin\MessageType;
2020
use PhpMyAdmin\ResponseRenderer;

src/Controllers/Table/StructureController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
use PhpMyAdmin\Http\ServerRequest;
2323
use PhpMyAdmin\Identifiers\DatabaseName;
2424
use PhpMyAdmin\Identifiers\TableName;
25-
use PhpMyAdmin\Index;
25+
use PhpMyAdmin\Indexes\Index;
2626
use PhpMyAdmin\Message;
2727
use PhpMyAdmin\Partitioning\Partition;
2828
use PhpMyAdmin\Query\Utilities;

src/CreateAddField.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
use PhpMyAdmin\Dbal\DatabaseInterface;
88
use PhpMyAdmin\Html\Generator;
99
use PhpMyAdmin\Identifiers\DatabaseName;
10+
use PhpMyAdmin\Indexes\Index;
1011
use PhpMyAdmin\Table\Table;
1112

1213
use function count;

0 commit comments

Comments
 (0)