84% lh-custom-dashboard

Code Review | LH Custom Dashboard

WordPress plugin LH Custom Dashboard scored 84% from 54 tests.

About plugin

  • Plugin page: lh-custom-dashboard
  • Plugin version: 1.25
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-5.5
  • WordPress version: 6.3.1
  • First release: Jul 17, 2015
  • Latest release: Oct 17, 2020
  • Number of updates: 14
  • Update frequency: every 137.1 days
  • Top authors: shawfactor (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,716 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.08MB] [CPU: ▼1.12ms] Passed 4 tests

An overview of server-side resources used by LH Custom Dashboard
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0841.36 ▼2.13
Dashboard /wp-admin3.38 ▲0.0850.78 ▲2.26
Posts /wp-admin/edit.php3.49 ▲0.1453.68 ▲7.48
Add New Post /wp-admin/post-new.php5.96 ▲0.0888.74 ▼8.56
Media Library /wp-admin/upload.php3.30 ▲0.0734.74 ▲3.94
Custom Dashboard /wp-admin/options-general.php?page=lh-custom-dashboard/lh-custom-dashboard.php3.3035.63

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_recent-posts
db_upgraded
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for LH Custom Dashboard
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲4713.26 ▼1.141.91 ▲0.0842.44 ▼6.50
Dashboard /wp-admin2,185 ▼35.91 ▲0.81107.51 ▼7.0136.35 ▼11.17
Posts /wp-admin/edit.php2,068 ▼212.01 ▼0.0336.21 ▼0.3729.45 ▼4.04
Add New Post /wp-admin/post-new.php1,528 ▲1418.35 ▲0.87591.06 ▼81.2362.16 ▲6.07
Media Library /wp-admin/upload.php1,370 ▼214.18 ▼0.0296.19 ▼8.0139.97 ▼8.99
Custom Dashboard /wp-admin/options-general.php?page=lh-custom-dashboard/lh-custom-dashboard.php9783.1252.0923.87

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 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
The following issues need your attention
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/lh-custom-dashboard/partials/options-general.php:1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/lh-custom-dashboard/partials/settings.php:1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/lh-custom-dashboard/partials/option-settings.php:1

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
4 plugin tags: dashboard, wp-admin, wordpress-custom-dashboard, custom-dashboard

lh-custom-dashboard/lh-custom-dashboard.php 92% from 13 tests

The primary PHP file in "LH Custom Dashboard" version 1.25 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Text Domain: The text domain should only use lowercase characters and dashes

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Everything looks great! No dangerous files found in this plugin386 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP528850363
JavaScript16623

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity50.00
▷ Minimum class complexity50.00
▷ Maximum class complexity50.00
Average method complexity2.63
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods30
▷ Static methods930.00%
▷ Public methods2893.33%
▷ Protected methods00.00%
▷ Private methods26.67%
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
There were not PNG files found in your plugin