|
33 | 33 | <rule ref="Generic.CodeAnalysis.UnnecessaryFinalModifier"/> |
34 | 34 | <rule ref="Generic.Classes.DuplicateClassName"/> |
35 | 35 | <rule ref="Generic.WhiteSpace.IncrementDecrementSpacing"/> |
36 | | - <rule ref="Generic.VersionControl.GitMergeConflict" /> |
| 36 | + <rule ref="Generic.VersionControl.GitMergeConflict"/> |
37 | 37 | <rule ref="Generic.Files.OneClassPerFile"/> |
38 | 38 | <rule ref="Generic.Files.OneInterfacePerFile"/> |
39 | 39 |
|
|
48 | 48 | <rule ref="Generic.PHP.ForbiddenFunctions"> |
49 | 49 | <properties> |
50 | 50 | <property name="forbiddenFunctions" type="array"> |
| 51 | + <element key="close" value="closedir"/> |
51 | 52 | <element key="sizeof" value="count"/> |
52 | 53 | <element key="delete" value="unset"/> |
53 | 54 | <element key="print" value="echo"/> |
|
57 | 58 | <element key="is_real" value="is_float"/> |
58 | 59 | <element key="is_integer" value="is_int"/> |
59 | 60 | <element key="is_double" value="is_float"/> |
| 61 | + <element key="is_long" value="is_int"/> |
60 | 62 | <element key="join" value="implode"/> |
61 | 63 | <element key="chop" value="rtrim"/> |
| 64 | + <element key="key_exists" value="array_key_exists"/> |
62 | 65 |
|
63 | 66 | <!-- Use `::class` keyword --> |
64 | 67 | <element key="get_called_class" value="`static::class`"/> |
|
96 | 99 |
|
97 | 100 | <rule ref="Squiz.PHP.NonExecutableCode"/> |
98 | 101 | <rule ref="Squiz.PHP.LowercasePHPFunctions"/> |
| 102 | + <rule ref="Squiz.Operators.ValidLogicalOperators"/> <!-- require `&&` and `||`, not `AND` and `OR` --> |
99 | 103 | <!-- Forbid spaces around `->` operator --> |
100 | 104 | <rule ref="Squiz.WhiteSpace.ObjectOperatorSpacing"> |
101 | 105 | <properties> |
|
105 | 109 |
|
106 | 110 | <!-- <rule ref="Squiz.Strings.ConcatenationSpacing"> |
107 | 111 | <properties> |
108 | | - <property name="spacing" value="1" /> |
109 | | - <property name="ignoreNewlines" value="true" /> |
| 112 | + <property name="spacing" value="1"/> |
| 113 | + <property name="ignoreNewlines" value="true"/> |
110 | 114 | </properties> |
111 | 115 | </rule> --> |
112 | 116 |
|
|
137 | 141 | <rule ref="SlevomatCodingStandard.Functions.UnusedInheritedVariablePassedToClosure"/> |
138 | 142 | <rule ref="SlevomatCodingStandard.Exceptions.DeadCatch"/> |
139 | 143 | <rule ref="SlevomatCodingStandard.Namespaces.UseSpacing"/> |
| 144 | +<!-- <rule ref="SlevomatCodingStandard.Namespaces.UnusedUses"/>--> |
140 | 145 | <rule ref="SlevomatCodingStandard.Namespaces.UselessAlias"/> |
141 | 146 | <rule ref="SlevomatCodingStandard.Namespaces.NamespaceSpacing"/> |
142 | 147 | <rule ref="SlevomatCodingStandard.Namespaces.UseFromSameNamespace"/> |
|
147 | 152 | <rule ref="SlevomatCodingStandard.TypeHints.ReturnTypeHintSpacing"/> |
148 | 153 | <rule ref="SlevomatCodingStandard.TypeHints.ParameterTypeHintSpacing"/> |
149 | 154 | <rule ref="SlevomatCodingStandard.TypeHints.NullTypeHintOnLastPosition"/> |
| 155 | + <rule ref="SlevomatCodingStandard.TypeHints.NullableTypeForNullDefaultValue"/> |
150 | 156 | <rule ref="SlevomatCodingStandard.Commenting.ForbiddenComments"/> |
151 | 157 | <rule ref="SlevomatCodingStandard.Commenting.InlineDocCommentDeclaration"/> |
152 | 158 | <rule ref="SlevomatCodingStandard.Operators.SpreadOperatorSpacing"> |
153 | 159 | <properties> |
154 | | - <property name="spacesCountAfterOperator" value="0" /> |
| 160 | + <property name="spacesCountAfterOperator" value="0"/> |
155 | 161 | </properties> |
156 | 162 | </rule> |
157 | 163 | <rule ref="SlevomatCodingStandard.ControlStructures.RequireNullCoalesceOperator"/> |
158 | 164 | <rule ref="SlevomatCodingStandard.ControlStructures.UselessTernaryOperator"/> |
159 | 165 | <rule ref="SlevomatCodingStandard.ControlStructures.UselessIfConditionWithReturn"/> |
160 | 166 | <rule ref="SlevomatCodingStandard.ControlStructures.DisallowContinueWithoutIntegerOperandInSwitch"/> |
161 | 167 |
|
| 168 | + <rule ref="Squiz.Arrays.ArrayBracketSpacing"/> |
| 169 | + <rule ref="SlevomatCodingStandard.Arrays.TrailingArrayComma"/> |
| 170 | + |
162 | 171 | <!-- <rule ref="SlevomatCodingStandard.ControlStructures.EarlyExit"> |
163 | 172 | <properties> |
164 | | - <property name="ignoreStandaloneIfInScope" value="0" /> |
| 173 | + <property name="ignoreStandaloneIfInScope" value="0"/> |
165 | 174 | </properties> |
166 | 175 | </rule> --> |
167 | 176 | <!--<rule ref="SlevomatCodingStandard.Operators.RequireCombinedAssignmentOperator"/>--> |
168 | 177 | <!--<rule ref="SlevomatCodingStandard.Namespaces.FullyQualifiedClassNameInAnnotation"/>--> |
169 | | - <!-- <rule ref="SlevomatCodingStandard.TypeHints.NullableTypeForNullDefaultValue"/> --> |
170 | | - <!-- <rule ref="SlevomatCodingStandard.Namespaces.UnusedUses"/> --> |
171 | 178 | <!--<rule ref="SlevomatCodingStandard.Functions.UnusedParameter"/>--> |
172 | 179 |
|
173 | 180 | <!-- |
|
0 commit comments