83% ecommerce-dashboard

Code Review | eCommerce Dashboard

WordPress plugin eCommerce Dashboard scored83%from 54 tests.

About plugin

  • Plugin page: ecommerce-dashboard
  • Plugin version: 1.0.8
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.1
  • WordPress version: 6.3.1
  • First release: Nov 19, 2013
  • Latest release: Dec 31, 2014
  • Number of updates: 35
  • Update frequency: every 11.6 days
  • Top authors: lordspace (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /3,992 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

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

An overview of server-side resources used by eCommerce Dashboard
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0136.79 ▼9.42
Dashboard /wp-admin3.32 ▲0.0145.00 ▲2.01
Posts /wp-admin/edit.php3.37 ▲0.0148.68 ▼1.17
Add New Post /wp-admin/post-new.php5.90 ▲0.0186.46 ▼4.73
Media Library /wp-admin/upload.php3.24 ▲0.0132.89 ▼0.40

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

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

Browser metrics Passed 4 tests

Checking browser requirements for eCommerce Dashboard
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,823 ▲8813.56 ▼0.821.62 ▼0.1042.04 ▼2.90
Dashboard /wp-admin2,226 ▲415.86 ▲0.0296.59 ▼4.1678.52 ▲33.82
Posts /wp-admin/edit.php2,109 ▲202.00 ▼0.0437.36 ▼2.8234.09 ▼0.57
Add New Post /wp-admin/post-new.php1,682 ▲14922.38 ▼0.76723.99 ▲48.5762.75 ▲11.13
Media Library /wp-admin/upload.php1,405 ▲174.22 ▼0.0095.29 ▼14.2472.49 ▲25.25

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 detected upon uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • 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
Please take a closer look at the following
  • 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/ecommerce-dashboard/ecommerce-dashboard.php:29

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need your attention:
  • Screenshots: Please add images for these screenshots: #1 (Plugin's Settings Page), #2 (Live demo (show sale stats))
  • Tags: Please delete some tags, you are using 22 tag instead of maximum 10
The official readme.txt might help

ecommerce-dashboard/ecommerce-dashboard.php 92% from 13 tests

The principal PHP file in "eCommerce Dashboard" v. 1.0.8 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 163 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Success! There were no dangerous files found in this plugin672 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP1139158638
CSS371126
JavaScript2068

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity5.33
▷ Minimum class complexity2.00
▷ Maximum class complexity8.00
Average method complexity5.33
▷ Minimum method complexity2.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods3
▷ Static methods133.33%
▷ Public methods3100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions18
▷ Named functions18100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
6 PNG files occupy 0.17MB with 0.04MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
i/guNzr.qr.2.png0.23KB0.23KB0.43%
screenshot-3.png18.84KB7.50KB▼ 60.20%
assets/icon.png0.62KB0.63KB0.00%
i/guNzr.qr.16.png0.39KB0.41KB0.00%
screenshot-2.png12.08KB5.31KB▼ 56.08%