Benchmarks
Plugin footprint 30% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully
Server metrics [RAM: ▲1.21MB] [CPU: ▲13.76ms] Passed 4 tests
This is a short check of server-side resources used by IP Location Block
This plugin does not affect your website's performance
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 4.42 ▲0.96 | 52.75 ▲8.18 |
Dashboard /wp-admin | 4.64 ▲1.34 | 72.74 ▲24.79 |
Posts /wp-admin/edit.php | 4.69 ▲1.34 | 65.31 ▲18.75 |
Add New Post /wp-admin/post-new.php | 7.16 ▲1.28 | 102.69 ▲3.31 |
Media Library /wp-admin/upload.php | 4.51 ▲1.28 | 68.13 ▲34.02 |
IP Location Block /wp-admin/options-general.php?page=ip-location-block | 4.99 | 55.28 |
Server storage [IO: ▲9.70MB] [DB: ▲0.01MB] Passed 3 tests
A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 640 new files
Database: 3 new tables, 7 new options
New tables |
---|
wp_ip_location_block_cache |
wp_ip_location_block_logs |
wp_ip_location_block_stat |
New WordPress options |
---|
widget_recent-posts |
widget_recent-comments |
can_compress_scripts |
theysaidso_admin_options |
ip_location_block_settings |
widget_theysaidso_widget |
db_upgraded |
Browser metrics Passed 4 tests
Checking browser requirements for IP Location Block
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,040 ▲278 | 13.52 ▼1.19 | 7.62 ▲5.78 | 41.48 ▼2.16 |
Dashboard /wp-admin | 2,333 ▲153 | 5.79 ▲0.15 | 100.09 ▲1.04 | 59.52 ▲16.10 |
Posts /wp-admin/edit.php | 2,244 ▲144 | 2.28 ▲0.27 | 40.61 ▲1.42 | 47.39 ▲14.86 |
Add New Post /wp-admin/post-new.php | 1,656 ▲121 | 23.40 ▲4.97 | 735.84 ▲127.35 | 57.12 ▼12.05 |
Media Library /wp-admin/upload.php | 1,535 ▲132 | 4.40 ▲0.25 | 121.30 ▲23.63 | 59.88 ▲16.27 |
IP Location Block /wp-admin/options-general.php?page=ip-location-block | 3,691 | 2.41 | 55.37 | 80.15 |
Uninstaller [IO: ▲20.78MB] [DB: ▲0.01MB] 0% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following itemsZombie tables were found after uninstall: 3 tables This plugin does not fully uninstall, leaving 8 options in the database
- This plugin did not uninstall without warnings or errors
- > Notice in wp-content/plugins/ip-location-block/uninstall.php+15
Constant IP_LOCATION_BLOCK_PATH already defined
- This plugin has failed uninstalling correctly, leaving 640 files (9.70MB) in the plugin directory
- (new file) admin/class-ip-location-block-admin.php
- (new file) admin/css/fonts/icomoon.svg
- (new file) admin/css/admin-icons.min.css
- (new file) admin/css/cidr.min.css
- (new file) admin/css/fonts/icomoon.woff
- (new file) admin/css/fonts/icomoon.ttf
- (new file) admin/css/admin.css
- (new file) admin/css/admin.min.css
- (new file) admin/css/fonts/icomoon.eot
- (new file) admin/css/admin-icons.css
- ...
- wp_ip_location_block_logs
- wp_ip_location_block_cache
- wp_ip_location_block_stat
- theysaidso_admin_options
- ip_location_block_settings
- db_upgraded
- recovery_mode_email_last_sent
- widget_recent-posts
- widget_theysaidso_widget
- can_compress_scripts
- 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
Everything seems fine, however this is by no means an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
The following issues need your attention
- 275× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
- > PHP Fatal error
Uncaught Error: Class 'phpseclib3\\Crypt\\EC\\BaseCurves\\Prime' not found in wp-content/plugins/ip-location-block/classes/db-providers/ip2location/vendor/phpseclib/phpseclib/phpseclib/Crypt/EC/Curves/secp160r2.php:21
- > PHP Fatal error
Uncaught Error: Class 'GeoIp2\\Record\\AbstractPlaceRecord' not found in wp-content/plugins/ip-location-block/classes/db-providers/maxmind/vendor/geoip2/geoip2/src/Record/Country.php:26
- > PHP Fatal error
Uncaught Error: Class 'GeoIp2\\Model\\AbstractModel' not found in wp-content/plugins/ip-location-block/classes/db-providers/maxmind/vendor/geoip2/geoip2/src/Model/Asn.php:16
- > PHP Fatal error
Uncaught Error: Class 'phpseclib3\\Math\\BigInteger\\Engines\\PHP' not found in wp-content/plugins/ip-location-block/classes/db-providers/ip2location/vendor/phpseclib/phpseclib/phpseclib/Math/BigInteger/Engines/PHP32.php:29
- > PHP Fatal error
Uncaught Error: Class 'phpseclib3\\Crypt\\EC\\BaseCurves\\Binary' not found in wp-content/plugins/ip-location-block/classes/db-providers/ip2location/vendor/phpseclib/phpseclib/phpseclib/Crypt/EC/Curves/sect131r2.php:21
- > PHP Fatal error
Uncaught Error: Class 'phpseclib3\\Crypt\\Common\\Formats\\Keys\\OpenSSH' not found in wp-content/plugins/ip-location-block/classes/db-providers/ip2location/vendor/phpseclib/phpseclib/phpseclib/Crypt/RSA/Formats/Keys/OpenSSH.php:32
- > PHP Fatal error
Uncaught Error: Class 'Net_DNS2_RR' not found in wp-content/plugins/ip-location-block/includes/Net/DNS2/RR/TSIG.php:44
- > PHP Fatal error
Uncaught Error: Class 'phpseclib3\\Crypt\\Common\\AsymmetricKey' not found in wp-content/plugins/ip-location-block/classes/db-providers/ip2location/vendor/phpseclib/phpseclib/phpseclib/Crypt/DH.php:44
- > PHP Fatal error
Uncaught Error: Class 'phpseclib3\\Crypt\\Common\\Formats\\Keys\\PKCS1' not found in wp-content/plugins/ip-location-block/classes/db-providers/ip2location/vendor/phpseclib/phpseclib/phpseclib/Crypt/EC/Formats/Keys/PKCS1.php:49
- > PHP Fatal error
Uncaught Error: Class 'phpseclib3\\Crypt\\EC\\BaseCurves\\Binary' not found in wp-content/plugins/ip-location-block/classes/db-providers/ip2location/vendor/phpseclib/phpseclib/phpseclib/Crypt/EC/Curves/sect113r1.php:21
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found
Optimizations
Plugin configuration 96% from 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
6 plugin tags: block, ip address, ip geo block, geolocation, ip...
ip-location-block/ip-location-block.php 92% from 13 tests
"IP Location Block" version 1.2.3's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please take the time to fix the following:
- Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 177 characters long)
Code Analysis 3% from 3 tests
File types 0% from 1 test
🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
It is important to fix the following items
- Do not include executable or dangerous files in your plugin
- .bin - Binary Executable in Windows, macOS, Linux
- ☣ wp-content/plugins/ip-location-block/classes/db-providers/ip2location/vendor/ip2location/ip2location-php/databases/IP2LOCATION-LITE-DB1.BIN
- .bin - Binary Executable in Windows, macOS, Linux
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 535 | 11,616 | 39,533 | 51,830 |
JavaScript | 20 | 9,947 | 22,034 | 34,526 |
CSS | 14 | 127 | 188 | 2,924 |
JSON | 2 | 0 | 0 | 576 |
C | 1 | 73 | 15 | 476 |
Markdown | 5 | 126 | 0 | 335 |
XML | 2 | 0 | 0 | 28 |
YAML | 1 | 2 | 0 | 25 |
SVG | 1 | 0 | 0 | 22 |
m4 | 1 | 5 | 0 | 14 |
C/C++ Header | 1 | 4 | 12 | 8 |
Bourne Shell | 1 | 2 | 0 | 3 |
PHP code 50% from 2 tests
Analyzing logical lines of code, cyclomatic complexity, and other code metrics
The following items need your attention
- Please reduce cyclomatic complexity of methods to less than 100 (currently 106)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.39 |
Average class complexity | 15.55 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 660.00 |
Average method complexity | 4.28 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 106.00 |
Code structure | ||
---|---|---|
Namespaces | 55 | |
Interfaces | 5 | |
Traits | 4 | |
Classes | 514 | |
▷ Abstract classes | 211 | 41.05% |
▷ Concrete classes | 303 | 58.95% |
▷ Final classes | 14 | 4.62% |
Methods | 2,281 | |
▷ Static methods | 719 | 31.52% |
▷ Public methods | 1,446 | 63.39% |
▷ Protected methods | 452 | 19.82% |
▷ Private methods | 383 | 16.79% |
Functions | 57 | |
▷ Named functions | 33 | 57.89% |
▷ Anonymous functions | 24 | 42.11% |
Constants | 576 | |
▷ Global constants | 48 | 8.33% |
▷ Class constants | 528 | 91.67% |
▷ Public constants | 528 | 100.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
Often times overlooked, PNG files can occupy unnecessary space in your plugin
15 compressed PNG files occupy 0.02MB
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
admin/vendor/leaflet/images/layers.png | 0.68KB | 1.05KB | 0.00% |
admin/vendor/leaflet/images/marker-icon-2x.png | 2.41KB | 2.52KB | 0.00% |
admin/images/alert.png | 0.46KB | 0.47KB | 0.00% |
admin/datatables/images/sort_asc_disabled.png | 0.10KB | 0.11KB | 0.00% |
admin/images/unlock.png | 0.40KB | 0.41KB | 0.00% |