Benchmarks
Plugin footprint 82% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲43.94MB] [CPU: ▲36.11ms] 50% from 4 tests
An overview of server-side resources used by Geo IP Library
Please have a look at the following items
- RAM: Total memory usage must be kept under 10MB (currently 47.95MB on /wp-admin/tools.php?page=geo-ip-library-settings)
- Extra RAM: Extra memory usage should kept under 5MB (currently 43.94MB on /wp-admin/tools.php?page=geo-ip-library-settings)
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 47.93 ▲44.47 | 79.01 ▲37.90 |
Dashboard /wp-admin | 47.95 ▲44.65 | 99.32 ▲45.11 |
Posts /wp-admin/edit.php | 47.95 ▲44.60 | 97.11 ▲47.79 |
Add New Post /wp-admin/post-new.php | 47.95 ▲42.06 | 117.90 ▲21.56 |
Media Library /wp-admin/upload.php | 47.95 ▲44.72 | 73.51 ▲39.85 |
Geo IP Library /wp-admin/tools.php?page=geo-ip-library-settings | 47.95 | 72.24 |
Server storage [IO: ▲3.59MB] [DB: ▲0.00MB] Passed 3 tests
How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 24 new files
Database: no new tables, 6 new options
New WordPress options |
---|
theysaidso_admin_options |
db_upgraded |
widget_recent-comments |
widget_recent-posts |
can_compress_scripts |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
An overview of browser requirements for Geo IP Library
This plugin renders optimally with no browser resource issues detected
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,829 ▲83 | 13.21 ▼1.16 | 2.03 ▲0.25 | 36.45 ▼6.30 |
Dashboard /wp-admin | 2,210 ▲19 | 4.84 ▼0.04 | 109.12 ▲2.37 | 39.65 ▼9.10 |
Posts /wp-admin/edit.php | 2,093 ▲4 | 2.00 ▼0.05 | 40.65 ▼3.06 | 35.93 ▼5.76 |
Add New Post /wp-admin/post-new.php | 1,546 ▲27 | 24.41 ▲0.91 | 642.80 ▲37.46 | 62.50 ▲13.73 |
Media Library /wp-admin/upload.php | 1,392 ▲1 | 4.22 ▲0.02 | 96.46 ▼8.04 | 40.02 ▼6.69 |
Geo IP Library /wp-admin/tools.php?page=geo-ip-library-settings | 1,130 | 1.68 | 23.64 | 51.56 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
- This plugin does not fully uninstall, leaving 6 options in the database
- db_upgraded
- widget_theysaidso_widget
- can_compress_scripts
- widget_recent-posts
- theysaidso_admin_options
- widget_recent-comments
Smoke tests 50% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test
SRP 0% 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
Please take a closer look at the following
- 1× PHP files output text when accessed directly:
- > /wp-content/plugins/geo-ip-library/geo-ip-library.php
- 3× GET requests to PHP files trigger server-side errors or Error 500 responses:
- > PHP Warning
require(GEO_IP_LIBRARY_PATHincludes/class-geoiplibrary.php): failed to open stream: No such file or directory in wp-content/plugins/geo-ip-library/includes/class-core.php on line 15
- > PHP Warning
Use of undefined constant GEO_IP_LIBRARY_PATH - assumed 'GEO_IP_LIBRARY_PATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/geo-ip-library/includes/class-core.php on line 15
- > PHP Fatal error
require(): Failed opening required 'GEO_IP_LIBRARY_PATHincludes/class-geoiplibrary.php' (include_path='.:/usr/share/php') in wp-content/plugins/geo-ip-library/includes/class-core.php on line 15
- > PHP Warning
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were 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
5 plugin tags: library, geo location, standalone, custom content, geo ip
geo-ip-library/geo-ip-library.php Passed 13 tests
"Geo IP Library" version 0.9.7's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
78 characters long description:
Provides simple country location features by using Chir's geolocation library.
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
No dangerous file extensions were detected4,593 lines of code in 19 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 8 | 97 | 398 | 3,236 |
CSS | 4 | 68 | 1 | 449 |
Sass | 2 | 89 | 0 | 428 |
JavaScript | 3 | 36 | 112 | 313 |
HTML | 2 | 0 | 0 | 167 |
PHP code Passed 2 tests
A short review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.30 |
Average class complexity | 5.33 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 9.00 |
Average method complexity | 2.30 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 7.00 |
Code structure | ||
---|---|---|
Namespaces | 1 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 6 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 6 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 20 | |
▷ Static methods | 3 | 15.00% |
▷ Public methods | 19 | 95.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 1 | 5.00% |
Functions | 2 | |
▷ Named functions | 2 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 4 | |
▷ Global constants | 4 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size Passed 2 tests
Image compression Passed 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 0.03MB with 0.02MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/img/logo_small.png | 11.74KB | 3.56KB | ▼ 69.67% |
assets/img/logo.png | 21.64KB | 6.14KB | ▼ 71.64% |