74% humancaptcha

Code Review | HumanCaptcha by Outerbridge

WordPress plugin HumanCaptcha by Outerbridge scored74%from 54 tests.

About plugin

  • Plugin page: humancaptcha
  • Plugin version: 4.1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7-5.8
  • WordPress version: 6.3.1
  • First release: Aug 27, 2011
  • Latest release: Aug 27, 2021
  • Number of updates: 63
  • Update frequency: every 58.0 days
  • Top authors: outerbridge (100%)

Code review

54 tests

User reviews

16 reviews

Install metrics

300+ active /11,332 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼6.54ms] Passed 4 tests

An overview of server-side resources used by HumanCaptcha by Outerbridge
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0342.83 ▼9.43
Dashboard /wp-admin3.33 ▲0.0250.95 ▼1.67
Posts /wp-admin/edit.php3.38 ▲0.0248.96 ▼6.88
Add New Post /wp-admin/post-new.php5.91 ▲0.0286.67 ▼8.16
Media Library /wp-admin/upload.php3.25 ▲0.0240.69 ▲4.89
HumanCaptcha /wp-admin/options-general.php?page=obr-hlc3.2636.66

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 12 new files
Database: 2 new tables, 7 new options
New tables
wp_obr_humancaptcha_qanda
wp_obr_humancaptcha_admin
New WordPress options
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget
obr_humancaptcha_version
widget_recent-posts
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

Checking browser requirements for HumanCaptcha by Outerbridge
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲8313.53 ▼0.701.94 ▲0.0043.98 ▲2.62
Dashboard /wp-admin2,207 ▲225.76 ▼0.06105.29 ▲5.4741.31 ▼4.58
Posts /wp-admin/edit.php2,093 ▲42.01 ▼0.0036.16 ▼5.0035.51 ▼3.92
Add New Post /wp-admin/post-new.php1,535 ▲2122.97 ▼0.50666.59 ▲33.4961.73 ▲9.09
Media Library /wp-admin/upload.php1,395 ▲44.17 ▼0.0595.92 ▼14.7844.00 ▼0.88
HumanCaptcha /wp-admin/options-general.php?page=obr-hlc1,3522.0324.8729.62

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • The uninstall procedure failed, leaving 2 tables in the database
    • wp_obr_humancaptcha_admin
    • wp_obr_humancaptcha_qanda
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_theysaidso_widget
    • db_upgraded
    • can_compress_scripts
    • obr_humancaptcha_version
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
The following issues need your attention
  • 4× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Notice
      Trying to get property 'prefix' of non-object in wp-content/plugins/humancaptcha/outerbridge-humancaptcha.php on line 50
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/humancaptcha/outerbridge-humancaptcha-admin.php:48
    • > PHP Notice
      Trying to get property 'prefix' of non-object in wp-content/plugins/humancaptcha/outerbridge-humancaptcha.php on line 48
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/humancaptcha/outerbridge-humancaptcha.php:58

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes:
  • Screenshots: These screenshots require images: #1 (screenshot-1.png shows how the question slots seamlessly into the comments section of the WordPress site.), #2 (screenshot-2.png shows the administration section of the Outerbridge HumanCaptcha plugin.)
Please take inspiration from this readme.txt

humancaptcha/outerbridge-humancaptcha.php 92% from 13 tests

The main PHP file in "HumanCaptcha by Outerbridge" ver. 4.1.1 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("humancaptcha.php" instead of "outerbridge-humancaptcha.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
Everything looks great! No dangerous files found in this plugin754 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP24556483
PO File3104102271

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity50.00
▷ Minimum class complexity50.00
▷ Maximum class complexity50.00
Average method complexity2.81
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods27
▷ Static methods00.00%
▷ Public methods27100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 0.16MB with 0.10MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png134.87KB49.05KB▼ 63.63%
screenshot-1.png32.31KB14.41KB▼ 55.41%