84% tcbd-woocommerce-recaptcha

Code Review | TCBD WooCommerce reCAPTCHA

WordPress plugin TCBD WooCommerce reCAPTCHA scored 84% from 54 tests.

About plugin

  • Plugin page: tcbd-woocommerce-...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.7.3
  • WordPress version: 6.3.1
  • First release: Mar 22, 2017
  • Latest release: Mar 22, 2017
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: tcoder (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 529 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼4.36ms] Passed 4 tests

This is a short check of server-side resources used by TCBD WooCommerce reCAPTCHA
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.15 ▼2.82
Dashboard /wp-admin3.31 ▲0.0145.11 ▼2.43
Posts /wp-admin/edit.php3.36 ▲0.0146.50 ▲4.00
Add New Post /wp-admin/post-new.php5.89 ▲0.0185.95 ▼12.44
Media Library /wp-admin/upload.php3.23 ▲0.0135.53 ▲0.27
TCBD WooCommerce reCAPTCHA /wp-admin/plugins.php?page=TCBD_WooCommerce_reCAPTCHA3.1828.84

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
db_upgraded
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for TCBD WooCommerce reCAPTCHA
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲6913.21 ▼1.151.71 ▲0.0344.18 ▲2.07
Dashboard /wp-admin2,213 ▲255.85 ▲0.9399.33 ▼14.5237.78 ▼5.17
Posts /wp-admin/edit.php2,093 ▲42.05 ▲0.0639.50 ▲3.2736.19 ▲3.31
Add New Post /wp-admin/post-new.php1,517 ▼217.69 ▼5.69690.44 ▲6.3558.61 ▲2.18
Media Library /wp-admin/upload.php1,392 ▲14.22 ▲0.0898.38 ▼14.2144.36 ▼6.67
TCBD WooCommerce reCAPTCHA /wp-admin/plugins.php?page=TCBD_WooCommerce_reCAPTCHA8792.0724.1230.26

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
    • > GET request to /wp-admin/plugins.php?page=TCBD_WooCommerce_reCAPTCHA
    • > Notice in wp-content/plugins/tcbd-woocommerce-recaptcha/plugin.php+99
    Undefined variable: tcbd_woo_site_key
    • > GET request to /wp-admin/plugins.php?page=TCBD_WooCommerce_reCAPTCHA
    • > Notice in wp-content/plugins/tcbd-woocommerce-recaptcha/plugin.php+106
    Undefined variable: tcbd_woo_secret_key
    • > GET request to /wp-admin/plugins.php?page=TCBD_WooCommerce_reCAPTCHA
    • > Notice in wp-content/plugins/tcbd-woocommerce-recaptcha/plugin.php+119
    Undefined variable: tcbd_woo_on

SRP Passed 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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/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
These attributes need your attention:
  • Tags: Too many tags (17 tag instead of maximum 10); only the first 5 tags are used in your directory listing
Please take inspiration from this readme.txt

tcbd-woocommerce-recaptcha/plugin.php 92% from 13 tests

The main file in "TCBD WooCommerce reCAPTCHA" v. 1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please make the necessary changes and fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("tcbd-woocommerce-recaptcha.php" instead of "plugin.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin147 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP25228147

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.44
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions7
▷ Named functions7100.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
No PNG files were detected