84% cf7-honeypot-plus

Code Review | Contact Form 7 Honeypot Plus

WordPress plugin Contact Form 7 Honeypot Plus scored84%from 54 tests.

About plugin

  • Plugin page: cf7-honeypot-plus
  • Plugin version: 1.0.2.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8-5.7
  • WordPress version: 6.3.1
  • First release: Aug 5, 2019
  • Latest release: Mar 30, 2021
  • Number of updates: 11
  • Update frequency: every 55.1 days
  • Top authors: wpdebuglog (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

400+ active /3,243 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.03MB] [CPU: ▼5.19ms] Passed 4 tests

This is a short check of server-side resources used by Contact Form 7 Honeypot Plus
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0437.03 ▼7.48
Dashboard /wp-admin3.33 ▲0.0344.36 ▼5.75
Posts /wp-admin/edit.php3.38 ▲0.0345.43 ▼2.36
Add New Post /wp-admin/post-new.php5.91 ▲0.0392.73 ▼5.18
Media Library /wp-admin/upload.php3.26 ▲0.0333.79 ▼1.69

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for Contact Form 7 Honeypot Plus
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲2913.64 ▼0.843.97 ▲1.8241.76 ▼3.25
Dashboard /wp-admin2,203 ▲154.87 ▼0.22108.25 ▼0.9940.92 ▼1.68
Posts /wp-admin/edit.php2,089 ▼01.98 ▼0.0240.47 ▲2.8236.26 ▲4.06
Add New Post /wp-admin/post-new.php1,535 ▼723.32 ▲5.25653.44 ▲33.5351.15 ▲1.30
Media Library /wp-admin/upload.php1,382 ▼34.19 ▲0.0294.29 ▼8.5142.66 ▼1.38

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The following issues need your attention
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/cf7-honeypot-plus/cf7-honeypot-plus.php:30

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 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
10 plugin tags: cf7, spam, antispam, forms, form...

cf7-honeypot-plus/cf7-honeypot-plus.php Passed 13 tests

The main file in "Contact Form 7 Honeypot Plus" v. 1.0.2.1 serves as a complement to information provided in readme.txt and as the entry point to the plugin
67 characters long description:
Adds honeypot plus anti-spam functionality to Contact Form 7 forms.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin139 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP15710115
JavaScript14024

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.22
Average class complexity17.00
▷ Minimum class complexity17.00
▷ Maximum class complexity17.00
Average method complexity2.60
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods10
▷ Static methods110.00%
▷ Public methods990.00%
▷ Protected methods00.00%
▷ Private methods110.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
There were not PNG files found in your plugin