77% eazy-cf-catpcha

Code Review | Eazy CF Captcha

WordPress plugin Eazy CF Captcha scored77%from 54 tests.

About plugin

  • Plugin page: eazy-cf-catpcha
  • Plugin version: 1.2.6
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 2.9.0-6.3
  • WordPress version: 6.3.1
  • First release: Jul 22, 2011
  • Latest release: Aug 3, 2023
  • Number of updates: 41
  • Update frequency: every 107.2 days
  • Top authors: playwithpixels (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

600+ active /13,385 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
Installer ran successfully

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

A check of server-side resources used by Eazy CF Captcha
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0535.52 ▼5.17
Dashboard /wp-admin3.33 ▲0.0345.66 ▼3.27
Posts /wp-admin/edit.php3.45 ▲0.0949.76 ▲1.29
Add New Post /wp-admin/post-new.php5.92 ▲0.0380.69 ▼9.48
Media Library /wp-admin/upload.php3.26 ▲0.0336.24 ▲2.00
Eazy CF Captcha /wp-admin/options-general.php?page=eazycfc3.2831.22

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 25 new files
Database: no new tables, 10 new options
New WordPress options
eazycfc_easy
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts
db_upgraded
widget_recent-comments
eazycfc_honeypot
theysaidso_admin_options
eazycfc_disable_comment_form
eazycfc_label_text

Browser metrics Passed 4 tests

Eazy CF Captcha: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.72 ▲0.101.52 ▼0.4440.59 ▼4.64
Dashboard /wp-admin2,199 ▲225.62 ▲0.0986.09 ▼15.9538.07 ▼5.53
Posts /wp-admin/edit.php2,104 ▲41.99 ▼0.1240.28 ▲4.4635.09 ▼0.85
Add New Post /wp-admin/post-new.php1,531 ▲523.42 ▲0.19688.18 ▲9.3958.04 ▲0.51
Media Library /wp-admin/upload.php1,407 ▲74.20 ▲0.0197.06 ▼9.8044.01 ▼6.05
Eazy CF Captcha /wp-admin/options-general.php?page=eazycfc9282.0321.9529.63

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test

SRP 0% 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
Please take a closer look at the following
  • 2× PHP files output text when accessed directly:
    • > /wp-content/plugins/eazy-cf-catpcha/views/public/captcha-field.php
    • > /wp-content/plugins/eazy-cf-catpcha/views/public/captcha.php
  • 54× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Notice
      Trying to get property 'bot_operator' of non-object in wp-content/plugins/eazy-cf-catpcha/views/public/captcha-field.php on line 6
    • > PHP Notice
      Trying to get property 'field_name' of non-object in wp-content/plugins/eazy-cf-catpcha/views/public/captcha-field.php on line 12
    • > PHP Notice
      Trying to get property 'var2' of non-object in wp-content/plugins/eazy-cf-catpcha/views/public/captcha-field.php on line 7
    • > PHP Notice
      Trying to get property 'container_class' of non-object in wp-content/plugins/eazy-cf-catpcha/views/public/captcha-field.php on line 1
    • > PHP Notice
      Trying to get property 'id' of non-object in wp-content/plugins/eazy-cf-catpcha/views/public/captcha-field.php on line 13
    • > PHP Fatal error
      Uncaught Error: Interface 'TK\\EazyCFCaptcha\\BasePlugin' not found in wp-content/plugins/eazy-cf-catpcha/includes/EazyCFCaptchaPlugin.php:15
    • > PHP Notice
      Trying to get property 'field_name' of non-object in wp-content/plugins/eazy-cf-catpcha/views/public/captcha-field.php on line 2
    • > PHP Fatal error
      Uncaught Error: Class 'TK\\EazyCFCaptcha\\PluginPublic\\EazyCFCPublicBase' not found in wp-content/plugins/eazy-cf-catpcha/includes/PluginPublic/EazyCFCPublicElementor.php:12
    • > PHP Notice
      Trying to get property 'operator' of non-object in wp-content/plugins/eazy-cf-catpcha/views/public/captcha-field.php on line 4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/eazy-cf-catpcha/views/admin/cf7-tag-pane.php:7

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 86% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
These attributes need to be fixed:
  • Tags: You are using too many tags: 18 tag instead of maximum 10
You can look at the official readme.txt

eazy-cf-catpcha/eazy-cf-captcha.php 77% from 13 tests

"Eazy CF Captcha" version 1.2.6's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("eazy-cf-catpcha.php" instead of "eazy-cf-captcha.php")
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Description: Please keep the plugin description shorter than 140 characters (currently 153 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Success! There were no dangerous files found in this plugin1,293 lines of code in 23 files:
LanguageFilesBlank linesComment linesLines of code
PHP212603961,185
PO File1303880
JavaScript17028

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity6.50
▷ Minimum class complexity1.00
▷ Maximum class complexity18.00
Average method complexity1.98
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces6
Interfaces1
Traits0
Classes15
▷ Abstract classes00.00%
▷ Concrete classes15100.00%
▷ Final classes00.00%
Methods92
▷ Static methods88.70%
▷ Public methods6368.48%
▷ Protected methods2931.52%
▷ Private methods00.00%
Functions1
▷ Named functions00.00%
▷ Anonymous functions1100.00%
Constants5
▷ Global constants5100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
PNG images were not found in this plugin