84% dokan-vendor-dashboard

Code Review | Dokan Vendor Dashboard

WordPress plugin Dokan Vendor Dashboard scored 84% from 54 tests.

About plugin

  • Plugin page: dokan-vendor-dash...
  • Plugin version: 1.0.1
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0.0-6.2.2
  • WordPress version: 6.3.1
  • First release: Feb 16, 2023
  • Latest release: Jun 9, 2023
  • Number of updates: 3
  • Update frequency: every 38.3 days
  • Top authors: wedevs (66.67%)tareq1988 (66.67%)

Code review

54 tests

User reviews

6 reviews

Install metrics

500+ active / 5,696 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.01MB] [CPU: ▼5.70ms] Passed 4 tests

A check of server-side resources used by Dokan Vendor Dashboard
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0238.99 ▼3.57
Dashboard /wp-admin3.32 ▲0.0145.95 ▼7.72
Posts /wp-admin/edit.php3.37 ▲0.0149.39 ▲3.56
Add New Post /wp-admin/post-new.php5.90 ▲0.0184.38 ▼14.07
Media Library /wp-admin/upload.php3.24 ▲0.0134.93 ▲2.55

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Dokan Vendor Dashboard
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,812 ▲7713.30 ▼1.145.59 ▲3.8844.47 ▲0.59
Dashboard /wp-admin2,215 ▲305.80 ▼0.01103.50 ▼2.3139.23 ▼0.55
Posts /wp-admin/edit.php2,100 ▲112.02 ▼0.0340.40 ▼2.8836.92 ▲3.99
Add New Post /wp-admin/post-new.php1,526 ▲1217.70 ▲0.24667.40 ▲35.1552.49 ▼0.94
Media Library /wp-admin/upload.php1,397 ▲64.27 ▲0.09104.47 ▲4.6446.88 ▲1.69

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • This plugin does not fully uninstall, leaving 7 options in the database
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • dokan_vendor_dashboard_version
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not 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 fix the following items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function language_attributes() in wp-content/plugins/dokan-vendor-dashboard/templates/vendor-dashboard-full-width.php:2

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

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
3 plugin tags: vendor dashboard, dokan, multivendor marketplace

dokan-vendor-dashboard/dokan-vendor-dashboard.php 92% from 13 tests

The principal PHP file in "Dokan Vendor Dashboard" v. 1.0.1 is loaded by WordPress automatically on each request
The following require your attention:
  • Requires at least: Required version must match the one declared in readme.txt ("5.8" instead of "5.0.0")

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
No dangerous file extensions were detected35,514 lines of code in 29 files:
LanguageFilesBlank linesComment linesLines of code
CSS447646332,728
PHP203291,0441,379
JSON2001,248
SVG187099
JavaScript210360

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity14.67
▷ Minimum class complexity1.00
▷ Maximum class complexity48.00
Average method complexity2.75
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes12
▷ Abstract classes00.00%
▷ Concrete classes12100.00%
▷ Final classes18.33%
Methods97
▷ Static methods2222.68%
▷ Public methods8890.72%
▷ Protected methods11.03%
▷ Private methods88.25%
Functions7
▷ Named functions114.29%
▷ Anonymous functions685.71%
Constants7
▷ Global constants7100.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