89% jr-dashboard-widget-editor

Code Review | JR : Dashboard Widget Editor

WordPress plugin JR : Dashboard Widget Editor scored 89% from 54 tests.

About plugin

  • Plugin page: jr-dashboard-widg...
  • Plugin version: 0.3.0
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.0.1
  • WordPress version: 6.3.1
  • First release: Jul 4, 2016
  • Latest release: Dec 13, 2018
  • Number of updates: 8
  • Update frequency: every 111.6 days
  • Top authors: jack russell (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 643 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

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

An overview of server-side resources used by JR : Dashboard Widget Editor
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0038.69 ▼1.87
Dashboard /wp-admin3.32 ▲0.0250.36 ▲0.08
Posts /wp-admin/edit.php3.37 ▲0.0148.02 ▲5.16
Add New Post /wp-admin/post-new.php5.90 ▲0.0295.02 ▲0.22
Media Library /wp-admin/upload.php3.24 ▲0.0131.61 ▼4.35
Dashboard- Customize /wp-admin/options-general.php?page=jr-bootstrap_plugin-dashboard3.2533.14
Dashboard- Add widgets /wp-admin/options-general.php?page=jr-bootstrap_plugin-dashboard_widget3.2729.97

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
db_upgraded
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
widget_theysaidso_widget

Browser metrics Passed 4 tests

JR : Dashboard Widget Editor: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,812 ▲7714.43 ▲0.051.76 ▼0.2342.80 ▼8.06
Dashboard /wp-admin2,221 ▲365.87 ▼0.05107.32 ▲7.4041.81 ▼0.50
Posts /wp-admin/edit.php2,101 ▲122.01 ▼0.0138.82 ▲2.4133.60 ▲1.30
Add New Post /wp-admin/post-new.php1,552 ▲3318.52 ▼4.87584.52 ▼140.5256.70 ▼7.32
Media Library /wp-admin/upload.php1,400 ▲124.17 ▼0.0198.92 ▼5.2642.20 ▼3.40
Dashboard- Customize /wp-admin/options-general.php?page=jr-bootstrap_plugin-dashboard8372.0223.9627.38
Dashboard- Add widgets /wp-admin/options-general.php?page=jr-bootstrap_plugin-dashboard_widget8362.0522.6525.57

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP Passed 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Everything seems fine, however this is by no means an exhaustive test

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 93% 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
1 plugin tags: widget

jr-dashboard-widget-editor/main.php 85% from 13 tests

This is the main PHP file of "JR : Dashboard Widget Editor" version 0.3.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Text Domain: The text domain should only use lowercase characters and dashes
  • Main file name: The principal plugin file should be the same as the plugin slug ("jr-dashboard-widget-editor.php" instead of "main.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 detected381 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP311160339
PO File1132042

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity24.00
▷ Minimum class complexity24.00
▷ Maximum class complexity24.00
Average method complexity3.33
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods8
▷ Static methods112.50%
▷ Public methods8100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions5
▷ Named functions00.00%
▷ Anonymous functions5100.00%
Constants3
▷ Global constants00.00%
▷ Class constants3100.00%
▷ Public constants3100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

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