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
This plugin's installer ran successfully
Server metrics [RAM: ▲0.04MB] [CPU: ▼1.73ms] Passed 4 tests
Analyzing server-side resources used by Player Leaderboard
This plugin has minimal impact on server resources
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.51 ▲0.05 | 37.21 ▼2.79 |
Dashboard /wp-admin | 3.35 ▲0.04 | 45.39 ▼10.48 |
Posts /wp-admin/edit.php | 3.46 ▲0.10 | 56.64 ▲11.82 |
Add New Post /wp-admin/post-new.php | 5.93 ▲0.04 | 97.61 ▲6.08 |
Media Library /wp-admin/upload.php | 3.27 ▲0.04 | 34.23 ▲0.28 |
New Result /wp-admin/admin.php?page=player-leaderboard-result | 3.45 | 32.89 |
New Player /wp-admin/admin.php?page=player-leaderboard-player | 3.49 | 40.37 |
New Results /wp-admin/admin.php?page=player-leaderboard-results-multiple | 3.33 | 33.36 |
Players /wp-admin/admin.php?page=player-leaderboard-players | 3.29 | 34.04 |
Results /wp-admin/admin.php?page=player-leaderboard-results | 3.30 | 33.40 |
New Competition /wp-admin/admin.php?page=player-leaderboard-competition | 3.57 | 33.33 |
Server storage [IO: ▲0.43MB] [DB: ▲0.08MB] Passed 3 tests
A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 41 new files
Database: 3 new tables, 7 new options
New tables |
---|
wp_player_leaderboard_player |
wp_player_leaderboard_result |
wp_player_leaderboard_competition |
New WordPress options |
---|
widget_recent-comments |
player_leaderboard_db_version |
db_upgraded |
theysaidso_admin_options |
widget_recent-posts |
can_compress_scripts |
widget_theysaidso_widget |
Browser metrics Passed 4 tests
An overview of browser requirements for Player Leaderboard
Normal browser usage
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 2,973 ▲238 | 13.88 ▼0.68 | 12.83 ▲10.74 | 37.15 ▼8.57 |
Dashboard /wp-admin | 2,223 ▲35 | 4.87 ▼0.01 | 109.17 ▼5.61 | 41.17 ▼3.31 |
Posts /wp-admin/edit.php | 2,103 ▲14 | 2.01 ▲0.04 | 39.83 ▼0.18 | 34.02 ▼0.04 |
Add New Post /wp-admin/post-new.php | 1,540 ▲26 | 23.44 ▲5.94 | 602.98 ▼76.56 | 51.34 ▲1.09 |
Media Library /wp-admin/upload.php | 1,405 ▲14 | 4.25 ▲0.05 | 103.08 ▲2.54 | 44.38 ▲1.04 |
New Result /wp-admin/admin.php?page=player-leaderboard-result | 793 | 2.03 | 36.90 | 23.64 |
New Player /wp-admin/admin.php?page=player-leaderboard-player | 835 | 2.00 | 36.27 | 24.20 |
New Results /wp-admin/admin.php?page=player-leaderboard-results-multiple | 793 | 1.97 | 26.66 | 24.47 |
Players /wp-admin/admin.php?page=player-leaderboard-players | 803 | 2.00 | 27.34 | 24.98 |
Results /wp-admin/admin.php?page=player-leaderboard-results | 816 | 2.00 | 25.64 | 26.12 |
New Competition /wp-admin/admin.php?page=player-leaderboard-competition | 2,246 | 2.66 | 71.47 | 31.39 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.07MB] 75% from 4 tests
🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
It is recommended to fix the following
- The uninstall procedure has failed, leaving 7 options in the database
- db_upgraded
- can_compress_scripts
- widget_theysaidso_widget
- theysaidso_admin_options
- widget_recent-posts
- widget_recent-comments
- player_leaderboard_db_version
Smoke tests 75% from 4 tests
Server-side errors Passed 1 test
🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though no errors were found, this is by no means an exhaustive test
SRP 50% from 2 tests
🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Almost there! Just fix the following items
- 21× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
- > PHP Notice
Undefined variable: atts in wp-content/plugins/player-leaderboard/public/partials/player-leaderboard-public-standing.php on line 18
- > PHP Fatal error
Uncaught Error: Call to undefined function current_user_can() in wp-content/plugins/player-leaderboard/admin/partials/player-leaderboard-results.php:16
- > PHP Fatal error
Uncaught Error: Call to undefined function current_user_can() in wp-content/plugins/player-leaderboard/admin/partials/player-leaderboard-players.php:16
- > PHP Fatal error
Uncaught Error: Call to undefined function current_user_can() in wp-content/plugins/player-leaderboard/admin/partials/player-leaderboard-results-multiple.php:16
- > PHP Notice
Undefined variable: atts in wp-content/plugins/player-leaderboard/public/partials/player-leaderboard-public-ranking.php on line 18
- > PHP Warning
Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/player-leaderboard/admin/class-player-leaderboard-players.php on line 20
- > PHP Warning
require_once(ABSPATHwp-admin/includes/class-wp-list-table.php): failed to open stream: No such file or directory in wp-content/plugins/player-leaderboard/admin/class-player-leaderboard-players.php on line 20
- > PHP Warning
Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/player-leaderboard/admin/class-player-leaderboard-results.php on line 20
- > PHP Fatal error
require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/player-leaderboard/admin/class-player-leaderboard-players.php on line 20
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/player-leaderboard/admin/class-player-leaderboard-admin.php:16
- > PHP Notice
User-side errors Passed 1 test
🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test
Optimizations
Plugin configuration Passed 29 tests
readme.txt Passed 16 tests
The readme.txt file uses markdown syntax to describe your plugin to the world
7 plugin tags: tennis, squash, rangliste, table tennis, ranking...
player-leaderboard/player-leaderboard.php Passed 13 tests
The main PHP file in "Player Leaderboard" ver. 1.0.2 adds more information about the plugin and also serves as the entry point for this plugin
34 characters long description:
Management of a player leaderboard
Code Analysis Passed 3 tests
File types Passed 1 test
🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
There were no executable files found in this plugin6,589 lines of code in 28 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 20 | 672 | 1,079 | 5,582 |
PO File | 1 | 218 | 429 | 425 |
CSS | 5 | 93 | 52 | 352 |
JavaScript | 2 | 29 | 0 | 230 |
PHP code Passed 2 tests
This plugin's cyclomatic complexity and code structure detailed below
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.48 |
Average class complexity | 76.29 |
▷ Minimum class complexity | 2.00 |
▷ Maximum class complexity | 204.00 |
Average method complexity | 5.75 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 100.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 7 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 7 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 111 | |
▷ Static methods | 8 | 7.21% |
▷ Public methods | 86 | 77.48% |
▷ Protected methods | 0 | 0.00% |
▷ Private methods | 25 | 22.52% |
Functions | 5 | |
▷ Named functions | 5 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 1 | |
▷ Global constants | 1 | 100.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
8 PNG files occupy 0.04MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
public/css/images/ui-icons_777777_256x240.png | 6.83KB | 4.17KB | ▼ 38.92% |
public/css/images/ui-icons_555555_256x240.png | 6.82KB | 4.17KB | ▼ 38.82% |
public/images/plus.png | 1.74KB | 1.47KB | ▼ 15.30% |
public/css/images/ui-icons_777620_256x240.png | 4.44KB | 4.17KB | ▼ 6.02% |
public/images/minus.png | 0.94KB | 1.25KB | 0.00% |