84% bvalidator

Code Review | bValidator

WordPress plugin bValidator scored84%from 54 tests.

About plugin

  • Plugin page: bvalidator
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-4.7
  • WordPress version: 6.3.1
  • First release: May 3, 2014
  • Latest release: Jan 1, 2017
  • Number of updates: 5
  • Update frequency: every 196.4 days
  • Top authors: enishant (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,139 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼7.70ms] Passed 4 tests

Server-side resources used by bValidator
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0132.69 ▼10.23
Dashboard /wp-admin3.31 ▲0.0143.92 ▼4.27
Posts /wp-admin/edit.php3.36 ▲0.0049.53 ▼1.63
Add New Post /wp-admin/post-new.php5.89 ▲0.0082.37 ▼14.67
Media Library /wp-admin/upload.php3.23 ▲0.0031.52 ▼1.60

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

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

Browser metrics Passed 4 tests

bValidator: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,854 ▲10813.29 ▼1.012.78 ▲0.9237.98 ▼2.97
Dashboard /wp-admin2,206 ▲155.90 ▲1.02112.34 ▲9.5642.11 ▼1.37
Posts /wp-admin/edit.php2,092 ▼01.96 ▼0.0340.74 ▼0.6434.74 ▼1.52
Add New Post /wp-admin/post-new.php1,514 ▼2417.44 ▼5.63675.62 ▲84.1654.24 ▲1.33
Media Library /wp-admin/upload.php1,388 ▲34.20 ▼0.00101.00 ▲6.1643.74 ▲1.39

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% 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 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following items
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bvalidator/index.php:17

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
7 plugin tags: validation, jquery, javascript, validate, bvalidator...

bvalidator/index.php 92% from 13 tests

The main file in "bValidator" v. 1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
You should first fix the following items:
  • Main file name: Name the main plugin file the same as the plugin slug ("bvalidator.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected816 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript120194688
PHP171075
CSS10453

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.10
Average class complexity5.00
▷ Minimum class complexity5.00
▷ Maximum class complexity5.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.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

Using a strong compression for your PNG files is a great way to speed-up your plugin
No PNG images were found in this plugin