68% gwp-captcha

Code Review | GWP-Captcha

WordPress plugin GWP-Captcha scored68%from 54 tests.

About plugin

  • Plugin page: gwp-captcha
  • Plugin version: 1.0
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.1.1
  • WordPress version: 6.3.1
  • First release: Jan 7, 2019
  • Latest release: Jan 21, 2023
  • Number of updates: 9
  • Update frequency: every 163.9 days
  • Top authors: karlkiesinger (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /608 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▼0.94MB] [CPU: ▼34.12ms] Passed 4 tests

A check of server-side resources used by GWP-Captcha
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0235.34 ▼3.45
Dashboard /wp-admin3.01 ▼0.3022.91 ▼24.66
Posts /wp-admin/edit.php3.01 ▼0.3525.35 ▼22.76
Add New Post /wp-admin/post-new.php3.01 ▼2.8822.24 ▼77.20
Media Library /wp-admin/upload.php3.01 ▼0.2220.75 ▼11.87

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 11 new options
New WordPress options
can_compress_scripts
gwpcaptcha_login
gwpcaptcha_lettercount
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
gwpcaptcha_register
gwpcaptcha_pluginversion
db_upgraded
...

Browser metrics Passed 4 tests

A check of browser resources used by GWP-Captcha
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,816 ▲7013.25 ▼0.971.60 ▲0.0140.46 ▼1.42
Dashboard /wp-admin2,219 ▲285.79 ▲0.8896.23 ▼13.9139.28 ▼7.74
Posts /wp-admin/edit.php2,108 ▲192.01 ▼0.0341.73 ▲5.9734.73 ▼2.19
Add New Post /wp-admin/post-new.php1,546 ▲3223.07 ▲5.43631.98 ▲16.5553.08 ▲1.26
Media Library /wp-admin/upload.php1,407 ▲194.18 ▼0.0298.45 ▼5.0542.24 ▼1.84

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin cannot be uninstalled
    • > User notice in wp-includes/functions.php+5905
    Function add_menu_page was called incorrectly. The seventh parameter passed to add_menu_page() should be numeric representing menu position. Please see Debugging in WordPress for more information. (This message was added in version 6.0.0.)
  • Zombie WordPress options were found after uninstall: 7 options
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments
    • gwpcaptcha_pluginversion

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 | 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
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/gwp-captcha/img.php
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/gwp-captcha/gwp-captcha.php:77

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
2 plugin tags: captcha, anti-spam bots

gwp-captcha/gwp-captcha.php 92% from 13 tests

The main file in "GWP-Captcha" v. 1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
  • Description: The description should be shorter than 140 characters (currently 167 characters long)

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 detected272 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP37642272

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.36
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%
Functions19
▷ Named functions19100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
There were not PNG files found in your plugin