Benchmarks
Plugin footprint 65% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed successfully, without throwing any errors or notices
Server metrics [RAM: ▲0.02MB] [CPU: ▼0.24ms] Passed 4 tests
Analyzing server-side resources used by WP Legisearch
No issues were detected with server-side resource usage
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.48 ▲0.02 | 42.13 ▲2.26 |
Dashboard /wp-admin | 3.32 ▲0.02 | 49.23 ▼1.34 |
Posts /wp-admin/edit.php | 3.38 ▲0.02 | 50.63 ▼0.54 |
Add New Post /wp-admin/post-new.php | 5.91 ▲0.02 | 100.78 ▼1.34 |
Media Library /wp-admin/upload.php | 3.25 ▲0.02 | 38.86 ▲2.39 |
Add Bill /wp-admin/admin.php?page=legisearch-add-bill | 3.19 | 29.26 |
Settings /wp-admin/admin.php?page=legisearch-settings | 3.26 | 35.88 |
All Bills /wp-admin/admin.php?page=legisearch-bill | 3.19 | 30.01 |
Server storage [IO: ▲0.11MB] [DB: ▲0.07MB] Passed 3 tests
Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 38 new files
Database: 3 new tables, 7 new options
New tables |
---|
wp_legisearch_os_cache |
wp_legisearch_votestracked |
wp_legisearch_billstracked |
New WordPress options |
---|
widget_recent-comments |
can_compress_scripts |
theysaidso_admin_options |
widget_theysaidso_widget |
db_upgraded |
widget_recent-posts |
legisearch_openstates_cachetimeout |
Browser metrics Passed 4 tests
WP Legisearch: 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,815 ▲29 | 14.19 ▼0.17 | 1.88 ▲0.14 | 43.51 ▼3.72 |
Dashboard /wp-admin | 2,209 ▲29 | 5.56 ▼0.12 | 95.01 ▼1.95 | 75.99 ▲34.57 |
Posts /wp-admin/edit.php | 2,129 ▲26 | 2.01 ▲0.01 | 35.92 ▼2.07 | 33.60 ▼0.69 |
Add New Post /wp-admin/post-new.php | 1,563 ▲37 | 22.84 ▼0.25 | 750.70 ▲71.43 | 53.95 ▲1.49 |
Media Library /wp-admin/upload.php | 1,423 ▲26 | 4.11 ▼0.12 | 108.57 ▲9.20 | 66.58 ▲21.07 |
Add Bill /wp-admin/admin.php?page=legisearch-add-bill | 695 | 1.51 | 8.16 | 17.61 |
Settings /wp-admin/admin.php?page=legisearch-settings | 898 | 2.18 | 29.77 | 31.49 |
All Bills /wp-admin/admin.php?page=legisearch-bill | 695 | 1.12 | 7.14 | 15.26 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.08MB] 50% from 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
- This plugin does not fully uninstall, leaving 3 tables in the database
- wp_legisearch_os_cache
- wp_legisearch_billstracked
- wp_legisearch_votestracked
- This plugin does not fully uninstall, leaving 7 options in the database
- widget_recent-posts
- theysaidso_admin_options
- db_upgraded
- can_compress_scripts
- widget_theysaidso_widget
- legisearch_openstates_cachetimeout
- widget_recent-comments
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
- 1× PHP files perform the action of outputting non-empty strings when accessed directly:
- > /wp-content/plugins/wp-legisearch/imagecache/index.php
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration 93% from 29 tests
readme.txt 94% from 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
These attributes need your attention:
- Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line (
=== wp-legisearch ===
)
wp-legisearch/legisearch.php 92% from 13 tests
This is the main PHP file of "WP Legisearch" version 1.3.3, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
- Main file name: The principal plugin file should be the same as the plugin slug ("wp-legisearch.php" instead of "legisearch.php")
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 detected2,012 lines of code in 33 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 28 | 207 | 205 | 1,769 |
JavaScript | 2 | 10 | 4 | 151 |
CSS | 3 | 6 | 0 | 92 |
PHP code Passed 2 tests
This is a very shot review of cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.29 |
Average class complexity | 9.90 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 26.00 |
Average method complexity | 2.48 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 9.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 1 | |
Traits | 0 | |
Classes | 9 | |
▷ Abstract classes | 1 | 11.11% |
▷ Concrete classes | 8 | 88.89% |
▷ Final classes | 0 | 0.00% |
Methods | 63 | |
▷ Static methods | 4 | 6.35% |
▷ Public methods | 52 | 82.54% |
▷ Protected methods | 1 | 1.59% |
▷ Private methods | 10 | 15.87% |
Functions | 33 | |
▷ Named functions | 33 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 24 | |
▷ Global constants | 20 | 83.33% |
▷ Class constants | 4 | 16.67% |
▷ Public constants | 4 | 100.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
2 compressed PNG files occupy 0.00MB
Potential savings
Compression of 2 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
images/wp-icon-36.png | 1.58KB | 1.43KB | ▼ 9.68% |
images/wp-icon-16.png | 0.61KB | 0.69KB | 0.00% |