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.39MB] [CPU: ▼31.23ms] Passed 4 tests
Server-side resources used by Custom Tabs & Fields for Woocommerce
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 2.21 ▼1.25 | 7.27 ▼34.76 |
Dashboard /wp-admin | 3.24 ▼0.10 | 30.44 ▼35.21 |
Posts /wp-admin/edit.php | 3.38 ▲0.03 | 34.34 ▼23.90 |
Add New Post /wp-admin/post-new.php | 5.63 ▼0.26 | 71.76 ▼31.05 |
Media Library /wp-admin/upload.php | 3.33 ▲0.10 | 29.60 ▼12.71 |
DB Optimize /wp-admin/admin.php?page=menu-posts-mg_wc_db_optimize | 3.23 | 27.66 |
Moodgiver Custom Tabs & Fields /wp-admin/admin.php?page=mg_wc_ctcf | 3.23 | 28.42 |
Custom Fields /wp-admin/admin.php?page=menu-posts-mg_wc_custom_fields | 3.23 | 27.75 |
Custom Tabs /wp-admin/edit.php?post_type=mg_wc_tab | 3.36 | 33.70 |
CSV Data Sample /wp-admin/admin.php?page=menu-posts-mg_wc_csv_sample | 3.23 | 27.18 |
Server storage [IO: ▲3.21MB] [DB: ▲0.00MB] Passed 3 tests
A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 38 new files
Database: no new tables, 6 new options
New WordPress options |
---|
db_upgraded |
widget_theysaidso_widget |
can_compress_scripts |
widget_recent-comments |
widget_recent-posts |
theysaidso_admin_options |
Browser metrics Passed 4 tests
This is an overview of browser requirements for Custom Tabs & Fields for Woocommerce
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,854 ▲108 | 13.39 ▼0.99 | 1.53 ▼0.12 | 41.60 ▲2.42 |
Dashboard /wp-admin | 2,256 ▲71 | 5.01 ▼0.80 | 113.03 ▼4.52 | 42.58 ▼5.28 |
Posts /wp-admin/edit.php | 2,146 ▲54 | 2.52 ▲0.47 | 40.09 ▲4.01 | 35.37 ▼2.23 |
Add New Post /wp-admin/post-new.php | 1,555 ▲13 | 23.18 ▲4.80 | 668.31 ▼44.39 | 59.89 ▼5.02 |
Media Library /wp-admin/upload.php | 1,435 ▲47 | 4.42 ▲0.20 | 100.03 ▼12.28 | 42.59 ▼3.78 |
DB Optimize /wp-admin/admin.php?page=menu-posts-mg_wc_db_optimize | 840 | 1.99 | 31.56 | 28.29 |
Moodgiver Custom Tabs & Fields /wp-admin/admin.php?page=mg_wc_ctcf | 943 | 1.90 | 30.62 | 34.59 |
Custom Fields /wp-admin/admin.php?page=menu-posts-mg_wc_custom_fields | 946 | 2.10 | 35.48 | 30.29 |
Custom Tabs /wp-admin/edit.php?post_type=mg_wc_tab | 1,131 | 2.27 | 34.77 | 29.21 |
CSV Data Sample /wp-admin/admin.php?page=menu-posts-mg_wc_csv_sample | 851 | 1.98 | 28.10 | 29.16 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
- Zombie WordPress options were found after uninstall: 6 options
- widget_theysaidso_widget
- widget_recent-posts
- theysaidso_admin_options
- widget_recent-comments
- db_upgraded
- can_compress_scripts
Smoke tests 75% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
- 5 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=menu-posts-mg_wc_csv_sample
- > Warning in wp-content/plugins/moodgiver-custom-tabs-fields-for-woocommerce/main.php+48
Use of undefined constant jQuery - assumed 'jQuery' (this will throw an Error in a future version of PHP)
- 5 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=menu-posts-mg_wc_csv_sample
- > Warning in wp-content/plugins/moodgiver-custom-tabs-fields-for-woocommerce/main.php+48
Use of undefined constant ui - assumed 'ui' (this will throw an Error in a future version of PHP)
- > GET request to /wp-admin/admin.php?page=menu-posts-mg_wc_db_optimize
- > Notice in wp-content/plugins/moodgiver-custom-tabs-fields-for-woocommerce/admin/moodgiver-ctcf-admin-custom-fields.php+210
Undefined index: run_db_optimize
- > GET request to /wp-admin/admin.php?page=menu-posts-mg_wc_db_optimize
- > Notice in wp-content/plugins/moodgiver-custom-tabs-fields-for-woocommerce/admin/moodgiver-ctcf-admin-custom-fields.php+226
Undefined variable: current
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=menu-posts-mg_wc_db_optimize
- > Notice in wp-content/plugins/moodgiver-custom-tabs-fields-for-woocommerce/admin/moodgiver-ctcf-admin-custom-fields.php+230
Undefined variable: optimize
SRP Passed 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
Congratulations! This plugin passed the SRP test
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side
Optimizations
Plugin configuration 90% 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
5 plugin tags: custom fields, product custom tabs, product custom fields, woocommerce, custom tabs
moodgiver-custom-tabs-fields-for-woocommerce/main.php 77% from 13 tests
The main PHP file in "Custom Tabs & Fields for Woocommerce" ver. 0.2a... adds more information about the plugin and also serves as the entry point for this plugin
You should first fix the following items:
- Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 329 characters long)
- Version: The version number should be digits and periods (ex. "1.0.3" instead of "0.2a...")
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("moodgiver-custom-tabs-fields-for-woocommerce.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
There were no executable files found in this plugin4,300 lines of code in 18 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
JavaScript | 4 | 594 | 216 | 1,679 |
PHP | 6 | 128 | 87 | 925 |
CSS | 5 | 19 | 16 | 797 |
JSON | 1 | 0 | 0 | 391 |
SVG | 1 | 0 | 0 | 288 |
PO File | 1 | 83 | 96 | 220 |
PHP code Passed 2 tests
Analyzing cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.31 |
Average class complexity | 46.00 |
▷ Minimum class complexity | 46.00 |
▷ Maximum class complexity | 46.00 |
Average method complexity | 3.14 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 9.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 1 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 1 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 21 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 21 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 12 | |
▷ Named functions | 12 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 0 | |
▷ Global constants | 0 | 0.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
6 PNG files occupy 1.48MB with 1.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/screenshot-3.png | 168.04KB | 47.93KB | ▼ 71.48% |
assets/screenshot-4.png | 124.22KB | 35.42KB | ▼ 71.48% |
assets/screenshot-2.png | 87.01KB | 27.90KB | ▼ 67.93% |
assets/screenshot-6.png | 219.96KB | 66.59KB | ▼ 69.73% |
assets/screenshot-1.png | 544.44KB | 175.35KB | ▼ 67.79% |