Benchmarks
Plugin footprint 83% 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 gracefully, with no errors
Server metrics [RAM: ▲0.35MB] [CPU: ▼5.00ms] Passed 4 tests
This is a short check of server-side resources used by Social Media Widget
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.82 ▲0.36 | 43.36 ▼1.03 |
Dashboard /wp-admin | 3.66 ▲0.35 | 45.78 ▼3.78 |
Posts /wp-admin/edit.php | 3.71 ▲0.35 | 47.30 ▼1.54 |
Add New Post /wp-admin/post-new.php | 6.26 ▲0.37 | 83.18 ▼13.63 |
Media Library /wp-admin/upload.php | 3.58 ▲0.35 | 36.63 ▲1.33 |
Server storage [IO: ▲1.70MB] [DB: ▲0.00MB] Passed 3 tests
Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 117 new files
Database: no new tables, 7 new options
New WordPress options |
---|
can_compress_scripts |
theysaidso_admin_options |
db_upgraded |
widget_recent-comments |
widget_recent-posts |
widget_social_media_widget |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
A check of browser resources used by Social Media Widget
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,895 ▲160 | 13.71 ▼0.96 | 5.36 ▲3.53 | 41.87 ▼5.17 |
Dashboard /wp-admin | 2,211 ▲20 | 4.87 ▼0.02 | 109.87 ▲3.31 | 42.07 ▼5.35 |
Posts /wp-admin/edit.php | 2,097 ▲8 | 2.05 ▲0.06 | 39.78 ▲0.71 | 34.47 ▼1.28 |
Add New Post /wp-admin/post-new.php | 1,522 ▲2 | 17.67 ▼5.45 | 670.79 ▼27.37 | 63.77 ▲11.67 |
Media Library /wp-admin/upload.php | 1,396 ▲5 | 4.19 ▼0.09 | 95.97 ▼4.20 | 44.22 ▼0.21 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Please fix the following items
- The uninstall procedure has failed, leaving 7 options in the database
- theysaidso_admin_options
- widget_recent-comments
- db_upgraded
- widget_social_media_widget
- widget_theysaidso_widget
- widget_recent-posts
- can_compress_scripts
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected
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
Please fix the following
- 1× PHP files trigger server-side errors or warnings when accessed directly:
- > PHP Fatal error
Uncaught Error: Call to undefined function add_action() in wp-content/plugins/social-media-widget-icon/social-media-widget-functions.php:12
- > PHP Fatal error
User-side errors Passed 1 test
🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need your attention:
- Tags: You are using too many tags: 11 tag instead of maximum 10
social-media-widget-icon/social-media-widget.php 85% from 13 tests
The main PHP script in "Social Media Widget" version 1.0 is automatically included on every request by WordPress
The following require your attention:
- Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("social-media-widget-icon.php" instead of "social-media-widget.php")
- Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
Code Analysis 97% from 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
There were no executable files found in this plugin6,211 lines of code in 7 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
CSS | 3 | 362 | 152 | 4,680 |
PHP | 2 | 75 | 26 | 963 |
SVG | 1 | 0 | 0 | 520 |
JavaScript | 1 | 6 | 0 | 48 |
PHP code 50% from 2 tests
A short review of cyclomatic complexity and code structure
The following items need your attention
- Cyclomatic complexity of methods has to be reduced to less than 100 (currently 891)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.88 |
Average class complexity | 948.00 |
▷ Minimum class complexity | 948.00 |
▷ Maximum class complexity | 948.00 |
Average method complexity | 316.67 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 891.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 | 3 | |
▷ Static methods | 0 | 0.00% |
▷ Public methods | 3 | 100.00% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 0 | 0.00% |
Functions | 2 | |
▷ Named functions | 2 | 100.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 50% from 2 tests
Image compression 50% from 2 tests
It is recommended to compress PNG files in your plugin to minimize bandwidth usage
105 PNG files occupy 0.86MB with 0.41MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
assets/img/default-linkedin.png | 1.07KB | 0.99KB | ▼ 6.87% |
assets/img/sprayed-facebook.png | 12.76KB | 5.29KB | ▼ 58.52% |
assets/img/social-badges-linkedin.png | 17.98KB | 6.47KB | ▼ 64.00% |
assets/img/white-rounded-twitter.png | 6.10KB | 2.95KB | ▼ 51.61% |
assets/img/social-christmas-linkedin.png | 10.53KB | 4.64KB | ▼ 55.96% |