Benchmarks
Plugin footprint 58% from 16 tests
Installer 0% from 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
It is recommended to fix the following installer errors
- The plugin cannot be installed
- > Error in wp-content/plugins/product-country-restrictions/product-country-restrictions.php+29
Uncaught Error: Class 'WC_Geolocation' not found in wp-content/plugins/product-country-restrictions/product-country-restrictions.php:29
Stack trace:
#0 wp-includes/class-wp-hook.php(310): FZ_Product_Country_Restrictions->on_activation()
#1 wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters()
#2 wp-includes/plugin.php(517): WP_Hook->do_action()
#3 wp-admin/includes/plugin.php(693): do_action()
Server metrics [RAM: ▲0.00MB] [CPU: ▼5.06ms] Passed 4 tests
This is a short check of server-side resources used by Product Country Restrictions
Server-side resource usage in normal parameters
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.46 ▲0.00 | 38.11 ▼7.01 |
Dashboard /wp-admin | 3.31 ▲0.00 | 43.64 ▼0.51 |
Posts /wp-admin/edit.php | 3.36 ▲0.00 | 48.40 ▲2.18 |
Add New Post /wp-admin/post-new.php | 5.89 ▲0.00 | 83.89 ▼1.81 |
Media Library /wp-admin/upload.php | 3.23 ▲0.00 | 32.30 ▼10.92 |
Server storage [IO: ▲0.02MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options |
---|
widget_recent-comments |
db_upgraded |
can_compress_scripts |
widget_recent-posts |
widget_theysaidso_widget |
theysaidso_admin_options |
Browser metrics Passed 4 tests
Product Country Restrictions: an overview of browser usage
There were no issues detected in relation to browser resource usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,825 ▲90 | 13.25 ▼1.15 | 1.78 ▼0.87 | 37.72 ▼17.68 |
Dashboard /wp-admin | 2,206 ▲15 | 5.82 ▼0.03 | 102.56 ▲0.53 | 37.13 ▼3.30 |
Posts /wp-admin/edit.php | 2,092 ▲3 | 2.04 ▲0.01 | 42.03 ▲7.52 | 40.63 ▲6.28 |
Add New Post /wp-admin/post-new.php | 1,533 ▼0 | 23.20 ▼0.00 | 671.74 ▲1.93 | 68.31 ▲15.46 |
Media Library /wp-admin/upload.php | 1,388 ▲6 | 4.23 ▲0.00 | 115.35 ▲4.26 | 52.05 ▲6.30 |
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
- The uninstall procedure has failed, leaving 6 options in the database
- widget_recent-posts
- db_upgraded
- widget_theysaidso_widget
- widget_recent-comments
- can_compress_scripts
- theysaidso_admin_options
Smoke tests Passed 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test
SRP Passed 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
Everything seems fine, however this is by no means an exhaustive test
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 96% 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
1 plugin tags: woocommerce
product-country-restrictions/product-country-restrictions.php 92% from 13 tests
The main file in "Product Country Restrictions" v. 0.4.3 serves as a complement to information provided in readme.txt and as the entry point to the plugin
Please take the time to fix the following:
- Requires at least: Required version does not match the one declared in readme.txt ("4.0" instead of "3.0")
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Success! There were no dangerous files found in this plugin264 lines of code in 2 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 1 | 46 | 11 | 226 |
PO File | 1 | 12 | 16 | 38 |
PHP code Passed 2 tests
A brief analysis of cyclomatic complexity and code structure for this plugin
There were no cyclomatic complexity issued detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.40 |
Average class complexity | 33.00 |
▷ Minimum class complexity | 33.00 |
▷ Maximum class complexity | 33.00 |
Average method complexity | 2.68 |
▷ 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 | 19 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 19 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 0 | |
▷ Named functions | 0 | 0.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 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
No PNG files were detected