90% wp-comment-form-js-validation

Code Review | WP Comment Form Js Validation

WordPress plugin WP Comment Form Js Validation scored90%from 54 tests.

About plugin

  • Plugin page: wp-comment-form-j...
  • Plugin version: 1.1
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.1-5.2
  • WordPress version: 6.3.1
  • First release: Jan 23, 2019
  • Latest release: Apr 26, 2020
  • Number of updates: 6
  • Update frequency: every 82.0 days
  • Top authors: urmilwp (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active /614 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
The plugin installed successfully, without throwing any errors or notices

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

A check of server-side resources used by WP Comment Form Js Validation
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0143.63 ▼5.58
Dashboard /wp-admin3.31 ▲0.0150.55 ▼6.10
Posts /wp-admin/edit.php3.36 ▲0.0153.39 ▲2.06
Add New Post /wp-admin/post-new.php5.89 ▲0.01102.50 ▼1.54
Media Library /wp-admin/upload.php3.24 ▲0.0136.99 ▼2.23

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
db_upgraded
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for WP Comment Form Js Validation
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5414.48 ▲0.101.80 ▼0.2044.68 ▼1.28
Dashboard /wp-admin2,206 ▲185.88 ▲0.08113.63 ▼2.3039.59 ▼6.36
Posts /wp-admin/edit.php2,092 ▲32.05 ▼0.0143.38 ▲4.3435.89 ▲0.39
Add New Post /wp-admin/post-new.php1,523 ▲423.15 ▼0.19615.01 ▼29.6753.73 ▲1.23
Media Library /wp-admin/upload.php1,385 ▼64.20 ▼0.0099.99 ▼12.0546.09 ▼2.16

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
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded

Smoke tests Passed 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 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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 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
7 plugin tags: advance comment form validation, comment form validation, plugin development, form validation, client side comment form validation...

wp-comment-form-js-validation/wp-comment-form-js-validation.php 92% from 13 tests

The primary PHP file in "WP Comment Form Js Validation" version 1.1 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Domain Path: The domain path points to an invalid folder, "/languages/" does not exist

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
There were no executable files found in this plugin94 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript211268
PHP141924
CSS1002

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.56
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%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 compressed PNG file occupies 0.02MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png17.89KB17.90KB0.00%