71% vip-grinders-leaderboards

Code Review | Plugin Name: VIP-Grinders Leaderboards

WordPress plugin Plugin Name: VIP-Grinders Leaderboardsscored71%from 54 tests.

About plugin

  • Plugin page: vip-grinders-lead...
  • Plugin version: 1.6
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.6.7-6.4.0
  • WordPress version: 6.3.1
  • First release: May 13, 2022
  • Latest release: Nov 8, 2023
  • Number of updates: 14
  • Update frequency: every 41.4 days
  • Top authors: vipgrinders (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active /787 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.12MB] [CPU: ▼8.39ms] 75% from 4 tests

Server-side resources used by Plugin Name: VIP-Grinders Leaderboards
It is recommended to improve the following
  • CPU: Total CPU usage should be kept under 500.00ms (currently 629.76ms on /wp-admin/admin.php?page=vipg-leaderboard-setup)
PageMemory (MB)CPU Time (ms)
Home /3.58 ▲0.1234.08 ▼4.23
Dashboard /wp-admin3.43 ▲0.0944.98 ▼18.06
Posts /wp-admin/edit.php3.55 ▲0.1946.56 ▲0.08
Add New Post /wp-admin/post-new.php6.02 ▲0.1384.19 ▼11.35
Media Library /wp-admin/upload.php3.36 ▲0.1335.67 ▲5.97
Help /wp-admin/admin.php?page=vipg-leaderboard-help3.3228.18
Get Short Code /wp-admin/admin.php?page=vipg-leaderboard-setup3.48629.76
VG Leaderboards /wp-admin/admin.php?page=vipg-leaderboard3.3230.63

Server storage [IO: ▲0.10MB] [DB: ▲0.00MB] Passed 3 tests

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 11 new files
Database: no new tables, 7 new options
New WordPress options
can_compress_scripts
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget
vglb_options
theysaidso_admin_options
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by Plugin Name: VIP-Grinders Leaderboards
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,828 ▲8114.37 ▲0.011.64 ▼0.0138.19 ▼5.70
Dashboard /wp-admin2,234 ▲575.74 ▲0.1798.78 ▼0.7941.44 ▼0.77
Posts /wp-admin/edit.php2,136 ▲362.04 ▲0.0444.05 ▲7.2536.25 ▲1.16
Add New Post /wp-admin/post-new.php1,557 ▲3123.32 ▼0.36619.82 ▼55.6654.08 ▼6.43
Media Library /wp-admin/upload.php1,439 ▲394.27 ▲0.02101.39 ▲4.1244.83 ▲2.69
Help /wp-admin/admin.php?page=vipg-leaderboard-help9602.0929.0931.80
Get Short Code /wp-admin/admin.php?page=vipg-leaderboard-setup4,9582.1230.4942.77
VG Leaderboards /wp-admin/admin.php?page=vipg-leaderboard3,7142.1929.8447.61

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Please fix the following server-side errors
    • > GET request to /wp-admin/admin.php?page=vipg-leaderboard-help
    • > POST request to /wp-admin/admin-ajax.php
    • > Notice in wp-content/plugins/vip-grinders-leaderboards/VIPG_LB_Setup.php+74
    Undefined index: promotion_id

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
Almost there! Just fix the following items
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/vip-grinders-leaderboards/vipg-leaderboard.php
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_die() in wp-content/plugins/vip-grinders-leaderboards/uninstall.php:4

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 79% from 29 tests

readme.txt 75% from 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
These attributes need your attention:
  • Requires at least: Invalid version format
  • Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line ( === Plugin Name: VIP-Grinders Leaderboards=== )
  • Contributors: Contributors not specified
  • Screenshots: No descriptions were found for these screenshots #1, #2, #3 in vip-grinders-leaderboards/assets to your readme.txt
Please take inspiration from this readme.txt

vip-grinders-leaderboards/vipg-leaderboard.php 85% from 13 tests

The primary PHP file in "Plugin Name: VIP-Grinders Leaderboards" version 1.6 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • 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
  • Main file name: Name the main plugin file the same as the plugin slug ("vip-grinders-leaderboards.php" instead of "vipg-leaderboard.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected874 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP514736614
JavaScript1480221
CSS110039

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.17
Average class complexity12.33
▷ Minimum class complexity1.00
▷ Maximum class complexity29.00
Average method complexity2.13
▷ Minimum method complexity1.00
▷ Maximum method complexity15.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods31
▷ Static methods31100.00%
▷ Public methods31100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions4
▷ Named functions125.00%
▷ Anonymous functions375.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.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
3 compressed PNG files occupy 0.06MB
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/setup_style_css.png34.98KB34.06KB▼ 2.62%
assets/setup_short_code_editor.png9.14KB8.16KB▼ 10.75%
assets/setup_short_code_page.png15.07KB14.17KB▼ 6.02%