Benchmarks
Plugin footprint 83% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully
Server metrics [RAM: ▲0.20MB] [CPU: ▼4.38ms] Passed 4 tests
Server-side resources used by Preferabli for WooCommerce
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.61 ▲0.15 | 37.70 ▼5.97 |
Dashboard /wp-admin | 3.52 ▲0.22 | 44.64 ▼5.65 |
Posts /wp-admin/edit.php | 3.63 ▲0.27 | 49.71 ▲1.81 |
Add New Post /wp-admin/post-new.php | 6.13 ▲0.24 | 82.18 ▼7.69 |
Media Library /wp-admin/upload.php | 3.40 ▲0.17 | 37.94 ▲4.76 |
Server storage [IO: ▲0.07MB] [DB: ▲0.00MB] Passed 3 tests
Filesystem and database footprint
The plugin installed successfully
Filesystem: 14 new files
Database: no new tables, 8 new options
New WordPress options |
---|
can_compress_scripts |
p4wc_plugin_options |
widget_theysaidso_widget |
widget_recent-posts |
p4wc_db_version |
theysaidso_admin_options |
widget_recent-comments |
db_upgraded |
Browser metrics Passed 4 tests
Checking browser requirements for Preferabli for WooCommerce
Minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,835 ▲89 | 13.33 ▼1.42 | 1.60 ▼0.41 | 40.21 ▼6.72 |
Dashboard /wp-admin | 2,241 ▲53 | 5.21 ▲0.33 | 114.17 ▲12.35 | 43.53 ▲2.54 |
Posts /wp-admin/edit.php | 2,129 ▲40 | 2.44 ▲0.40 | 41.97 ▲7.83 | 36.07 ▲2.73 |
Add New Post /wp-admin/post-new.php | 1,541 ▲11 | 23.38 ▲0.16 | 682.91 ▲10.37 | 36.57 ▼31.54 |
Media Library /wp-admin/upload.php | 1,423 ▲38 | 4.38 ▲0.22 | 93.82 ▼9.82 | 40.42 ▼3.04 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
- This plugin did not uninstall successfully, leaving 7 options in the database
- widget_theysaidso_widget
- widget_recent-posts
- widget_recent-comments
- can_compress_scripts
- db_upgraded
- theysaidso_admin_options
- p4wc_db_version
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Everything seems fine, however this is by no means an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
- 3× PHP files trigger errors when accessed directly with GET requests:
- > PHP Fatal error
Uncaught Error: Call to undefined function is_plugin_active() in wp-content/plugins/preferabli-for-woocommerce/templates/admin.php:9
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/preferabli-for-woocommerce/inc/preferabli-label-post-type.php:36
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/preferabli-for-woocommerce/inc/admin.php:29
- > PHP Fatal error
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 Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
4 plugin tags: beer, woocommerce, spirits, wine
preferabli-for-woocommerce/preferabli-for-woocommerce.php Passed 13 tests
The main PHP file in "Preferabli for WooCommerce" ver. 2.7 adds more information about the plugin and also serves as the entry point for this plugin
63 characters long description:
Integrate Preferabli functionality into your WooCommerce store.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
No dangerous file extensions were detected1,178 lines of code in 13 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 11 | 224 | 151 | 1,170 |
JavaScript | 1 | 4 | 1 | 7 |
SVG | 1 | 0 | 0 | 1 |
PHP code Passed 2 tests
This plugin's cyclomatic complexity and code structure detailed below
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.41 |
Average class complexity | 18.14 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 46.00 |
Average method complexity | 5.44 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 23.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 7 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 7 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 27 | |
▷ Static methods | 7 | 25.93% |
▷ Public methods | 21 | 77.78% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 6 | 22.22% |
Functions | 32 | |
▷ Named functions | 30 | 93.75% |
▷ Anonymous functions | 2 | 6.25% |
Constants | 2 | |
▷ Global constants | 2 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG images were found in this plugin