Skip to content

Commit

Permalink
Remove WordPressVIPMinimum.Functions.RestrictedFunctions.get_super_ad…
Browse files Browse the repository at this point in the history
…mins_get_super_admins
  • Loading branch information
rebeccahum committed Mar 29, 2021
1 parent 8383d16 commit 164d67f
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 15 deletions.
3 changes: 0 additions & 3 deletions WordPress-VIP-Go/ruleset.xml
Original file line number Diff line number Diff line change
Expand Up @@ -279,9 +279,6 @@
<rule ref="WordPressVIPMinimum.Variables.RestrictedVariables.user_meta__wpdb__usermeta">
<severity>0</severity>
</rule>
<rule ref="WordPressVIPMinimum.Functions.RestrictedFunctions.get_super_admins_get_super_admins">
<severity>0</severity>
</rule>
<rule ref="Generic.PHP.DisallowShortOpenTag.EchoFound">
<severity>0</severity>
</rule>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,13 +50,6 @@ public function getGroups() {
'opcache_get_configuration',
],
],
'get_super_admins' => [
'type' => 'error',
'message' => '`%s` is prohibited on the WordPress.com VIP platform.',
'functions' => [
'get_super_admins',
],
],
'internal' => [
'type' => 'error',
'message' => '`%1$s()` is for internal use only.',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ opcache_get_status(); // Error.
opcache_get_status( false ); // Error.
opcache_get_configuration(); // Error.

get_super_admin(); // Ok - similarly-named function to get_super_admins().
get_super_admins(); // Error.



vip_irc(); // Ok - similarly-named function to wpcom_vip_irc().
wpcom_vip_irc(); // Error.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ public function getErrorList() {
32 => 1,
33 => 1,
34 => 1,
37 => 1,
40 => 1,
43 => 1,
46 => 1,
Expand Down
2 changes: 1 addition & 1 deletion WordPressVIPMinimum/ruleset-test.inc
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ opcache_compile_file( $var ); // Error.
opcache_is_script_cached( 'test_script.php' ); // Error.
opcache_get_status(); // Error.
opcache_get_configuration(); // Error.
get_super_admins(); // Error.

wpcom_vip_irc(); // Error.
flush_rewrite_rules(); // Error.
$wp_rewrite->flush_rules(); // Error.
Expand Down
1 change: 0 additions & 1 deletion WordPressVIPMinimum/ruleset-test.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,6 @@
315 => 1,
316 => 1,
317 => 1,
318 => 1,
319 => 1,
320 => 1,
321 => 1,
Expand Down

0 comments on commit 164d67f

Please sign in to comment.