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.02MB] [CPU: ▼4.33ms] Passed 4 tests
Server-side resources used by Currency Switcher for WooCommerce
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.49 ▲0.03 | 43.91 ▲1.37 |
Dashboard /wp-admin | 3.33 ▲0.03 | 46.23 ▼4.09 |
Posts /wp-admin/edit.php | 3.38 ▲0.02 | 46.59 ▼3.45 |
Add New Post /wp-admin/post-new.php | 5.91 ▲0.02 | 94.21 ▼7.66 |
Media Library /wp-admin/upload.php | 3.25 ▲0.02 | 34.62 ▼2.12 |
Server storage [IO: ▲3.02MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 397 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_theysaidso_widget |
widget_recent-comments |
can_compress_scripts |
theysaidso_admin_options |
widget_recent-posts |
db_upgraded |
Browser metrics Passed 4 tests
A check of browser resources used by Currency Switcher for WooCommerce
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,800 ▲65 | 14.48 ▼0.12 | 1.75 ▼0.06 | 41.84 ▼3.35 |
Dashboard /wp-admin | 2,209 ▲24 | 5.91 ▲0.12 | 94.68 ▼4.16 | 35.51 ▼2.75 |
Posts /wp-admin/edit.php | 2,089 ▼0 | 2.00 ▼0.03 | 35.77 ▼3.22 | 34.82 ▼0.83 |
Add New Post /wp-admin/post-new.php | 1,534 ▼3 | 23.18 ▲4.69 | 644.46 ▲38.21 | 60.80 ▲5.60 |
Media Library /wp-admin/upload.php | 1,391 ▲3 | 4.27 ▲0.07 | 97.50 ▲1.01 | 44.13 ▲0.57 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
- Zombie WordPress options detected upon uninstall: 6 options
- db_upgraded
- theysaidso_admin_options
- widget_theysaidso_widget
- widget_recent-posts
- can_compress_scripts
- widget_recent-comments
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested
SRP 50% from 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
Please take a closer look at the following
- 22× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_url() in wp-content/plugins/currency-switcher-for-woocommerce/pmcs.php:42
- > PHP Fatal error
Uncaught Error: Class 'PMCS_Setting_Abstract' not found in wp-content/plugins/currency-switcher-for-woocommerce/includes/admin/class-pmcs-settings-geoip.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/currency-switcher-for-woocommerce/includes/class-pmcs-report.php:135
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/currency-switcher-for-woocommerce/includes/metabox/coupon-meta.php:3
- > PHP Fatal error
Uncaught Error: Class 'PMCS_Setting_Abstract' not found in wp-content/plugins/currency-switcher-for-woocommerce/includes/admin/class-pmcs-settings-license.php:3
- > PHP Fatal error
Uncaught Error: Class 'PMCS_Setting_Abstract' not found in wp-content/plugins/currency-switcher-for-woocommerce/includes/admin/class-pmcs-settings-switcher.php:3
- > PHP Fatal error
Uncaught Error: Class 'PMCS_Exchange_Server_Abstract' not found in wp-content/plugins/currency-switcher-for-woocommerce/includes/exchange-rate-api/class-server-yahoo.php:3
- > PHP Fatal error
Uncaught Error: Class 'PMCS_Exchange_Server_Abstract' not found in wp-content/plugins/currency-switcher-for-woocommerce/includes/exchange-rate-api/class-server-openexchangerates.php:3
- > PHP Fatal error
Uncaught Error: Call to undefined function get_woocommerce_currencies() in wp-content/plugins/currency-switcher-for-woocommerce/includes/admin/fields/currency-list.php:77
- > PHP Fatal error
Uncaught Error: Class 'PMCS_Setting_Abstract' not found in wp-content/plugins/currency-switcher-for-woocommerce/includes/admin/class-pmcs-settings-exchange-rate.php:3
- > PHP Fatal error
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 83% from 29 tests
readme.txt 88% from 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
Attributes that need to be fixed:
- Screenshots: Add descriptions for screenshots #1, #10, #2, #3, #4, #5, #6, #7, #8, #9 in currency-switcher-for-woocommerce/assets to your readme.txt
- Donate link: Please fix this invalid url: ""
currency-switcher-for-woocommerce/pmcs.php 77% from 13 tests
The entry point to "Currency Switcher for WooCommerce" version 0.0.7 is a PHP file that has certain tags in its header comment area
It is important to fix the following:
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("currency-switcher-for-woocommerce.php" instead of "pmcs.php")
- Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
- Requires at least: Required version does not match the one declared in readme.txt ("4.5" instead of "5.0")
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
Success! There were no dangerous files found in this plugin3,935 lines of code in 44 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 31 | 622 | 671 | 2,883 |
JavaScript | 3 | 97 | 33 | 560 |
Sass | 2 | 12 | 3 | 268 |
CSS | 3 | 16 | 8 | 193 |
JSON | 1 | 0 | 0 | 23 |
Markdown | 4 | 4 | 0 | 8 |
PHP code Passed 2 tests
An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.28 |
Average class complexity | 12.81 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 108.00 |
Average method complexity | 2.70 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 20.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 27 | |
▷ Abstract classes | 2 | 7.41% |
▷ Concrete classes | 25 | 92.59% |
▷ Final classes | 0 | 0.00% |
Methods | 188 | |
▷ Static methods | 3 | 1.60% |
▷ Public methods | 183 | 97.34% |
▷ Protected methods | 4 | 2.13% |
▷ Private methods | 1 | 0.53% |
Functions | 12 | |
▷ Named functions | 12 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 5 | |
▷ Global constants | 5 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
347 PNG files occupy 1.56MB with 0.27MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/flags/flags-normal/bd.png | 2.26KB | 2.41KB | 0.00% |
assets/flags/flags-normal/kp.png | 3.15KB | 3.42KB | 0.00% |
assets/flags/cdf.png | 3.11KB | 1.64KB | ▼ 47.27% |
assets/flags/flags-normal/lr.png | 2.11KB | 2.14KB | 0.00% |
assets/flags/flags-normal/pa.png | 4.54KB | 2.78KB | ▼ 38.84% |