78% blacklist-keys-manager

Code Review | Blacklist keys manager

WordPress plugin Blacklist keys manager scored78%from 54 tests.

About plugin

  • Plugin page: blacklist-keys-ma...
  • Plugin version: 1.2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.0-4.2.2
  • WordPress version: 6.3.1
  • First release: Sep 13, 2013
  • Latest release: May 22, 2015
  • Number of updates: 7
  • Update frequency: every 88.0 days
  • Top authors: tmatsuur (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,361 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.15MB] [CPU: ▼10.76ms] Passed 4 tests

An overview of server-side resources used by Blacklist keys manager
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.62 ▲0.1534.51 ▼10.88
Dashboard /wp-admin3.46 ▲0.1246.94 ▼19.53
Posts /wp-admin/edit.php3.57 ▲0.2249.86 ▲3.70
Add New Post /wp-admin/post-new.php6.04 ▲0.1684.12 ▼10.94
Media Library /wp-admin/upload.php3.38 ▲0.1634.70 ▼1.67
Comment Blacklist /wp-admin/options-general.php?page=blacklist-keys-manager-properties3.3530.97

Server storage [IO: ▲0.11MB] [DB: ▲0.00MB] Passed 3 tests

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 7 new files
Database: no new tables, 8 new options
New WordPress options
widget_recent-comments
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
blacklist-keys-manager-properties
theysaidso_admin_options
blacklist-keys-manager-db-version
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for Blacklist keys manager
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲2214.34 ▼0.311.59 ▼0.3639.16 ▼5.04
Dashboard /wp-admin2,196 ▲255.55 ▼0.0183.65 ▼5.9337.37 ▼4.70
Posts /wp-admin/edit.php2,104 ▲42.10 ▲0.0842.07 ▲7.7636.01 ▼2.06
Add New Post /wp-admin/post-new.php1,529 ▼723.11 ▲4.94670.35 ▲75.0758.05 ▼14.62
Media Library /wp-admin/upload.php1,401 ▲14.19 ▼0.0498.50 ▼7.1241.90 ▼4.15
Comment Blacklist /wp-admin/options-general.php?page=blacklist-keys-manager-properties1,9163.96104.4536.31

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin does not fully uninstall, leaving 7 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • blacklist-keys-manager-db-version
    • db_upgraded
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Please fix the following server-side errors
    • > GET request to /wp-admin/options-general.php?page=blacklist-keys-manager-properties
    • > User deprecated in wp-includes/functions.php+5737
    Function get_option was called with an argument that is deprecated since version 5.5.0! The "blacklist_keys" option key has been renamed to "disallowed_keys".

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function delete_option() in wp-content/plugins/blacklist-keys-manager/uninstall.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function load_plugin_textdomain() in wp-content/plugins/blacklist-keys-manager/blacklist-keys-manager.php:25

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need your attention:
  • Screenshots: Screenshot #1 (Properties page.) image missing
The official readme.txt might help

blacklist-keys-manager/blacklist-keys-manager.php Passed 13 tests

The entry point to "Blacklist keys manager" version 1.2.0 is a PHP file that has certain tags in its header comment area
40 characters long description:
This plugin manages a comment blacklist.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected1,041 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP32234894
PO File15573147

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.56
Average class complexity156.00
▷ Minimum class complexity156.00
▷ Maximum class complexity156.00
Average method complexity9.61
▷ Minimum method complexity1.00
▷ Maximum method complexity69.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods18
▷ Static methods00.00%
▷ Public methods1583.33%
▷ Protected methods00.00%
▷ Private methods316.67%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants466.67%
▷ Class constants233.33%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
1 compressed PNG file occupies 0.05MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png49.03KB45.01KB▼ 8.20%