Skip to content

Commit 7112177

Browse files
authored
PHPCS: Enable CommentedOutCode sniff (#914)
1 parent cefed60 commit 7112177

File tree

4 files changed

+3
-4
lines changed

4 files changed

+3
-4
lines changed

includes/class-hashtag.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ public static function init() {
2828
* @return array the activity object array
2929
*/
3030
public static function filter_activity_object( $object_array ) {
31-
/*
31+
/* phpcs:ignore Squiz.PHP.CommentedOutCode.Found
3232
Removed until this is merged: https://github.com/mastodon/mastodon/pull/28629
3333
if ( ! empty( $object_array['summary'] ) ) {
3434
$object_array['summary'] = self::the_content( $object_array['summary'] );

includes/class-link.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public static function init() {
2424
* @return array the activity object array
2525
*/
2626
public static function filter_activity_object( $object_array ) {
27-
/*
27+
/* phpcs:ignore Squiz.PHP.CommentedOutCode.Found
2828
Removed until this is merged: https://github.com/mastodon/mastodon/pull/28629
2929
if ( ! empty( $object_array['summary'] ) ) {
3030
$object_array['summary'] = self::the_content( $object_array['summary'] );

includes/collection/class-interactions.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,7 @@ function () {
310310
if ( 1 === $state ) {
311311
return $commentdata;
312312
} else {
313-
return $state; // Either `WP_Comment`, `false` or a `WP_Error` instance or `0` or `1`!
313+
return $state; // Either WP_Comment, false, a WP_Error, 0, or 1!
314314
}
315315
}
316316
}

phpcs.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626
<rule ref="WordPress">
2727
<exclude name="Generic.CodeAnalysis.UnusedFunctionParameter"/>
2828
<exclude name="Squiz.Commenting"/>
29-
<exclude name="Squiz.PHP.CommentedOutCode.Found"/>
3029
<exclude name="Universal.NamingConventions.NoReservedKeywordParameterNames"/>
3130
</rule>
3231
<rule ref="VariableAnalysis">

0 commit comments

Comments
 (0)