83% football-preloader

Code Review | Football Preloader

WordPress plugin Football Preloader scored83%from 54 tests.

About plugin

  • Plugin page: football-preloader
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.4.2
  • WordPress version: 6.3.1
  • First release: Mar 2, 2016
  • Latest release: Mar 3, 2016
  • Number of updates: 4
  • Update frequency: every 3.5 days
  • Top authors: bikel (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /963 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Install script ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼2.99ms] Passed 4 tests

Server-side resources used by Football Preloader
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0051.38 ▲13.87
Dashboard /wp-admin3.31 ▲0.0052.05 ▼12.43
Posts /wp-admin/edit.php3.36 ▲0.0051.17 ▼2.95
Add New Post /wp-admin/post-new.php5.89 ▲0.00135.86 ▲26.17
Media Library /wp-admin/upload.php3.23 ▲0.0031.07 ▼10.43

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

Analyzing filesystem and database footprints of this plugin
This plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for Football Preloader
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,822 ▲6114.37 ▼0.362.55 ▲0.8848.80 ▲6.32
Dashboard /wp-admin2,189 ▲95.60 ▲0.05125.06 ▲29.8658.89 ▲19.62
Posts /wp-admin/edit.php2,103 ▲61.95 ▼0.0843.14 ▲5.7140.21 ▲8.33
Add New Post /wp-admin/post-new.php1,409 ▼11917.93 ▼5.08796.46 ▲119.1263.10 ▲3.51
Media Library /wp-admin/upload.php1,400 ▼04.22 ▼0.02103.86 ▼14.1542.18 ▼11.32

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded
    • 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
Even though no errors were found, this is by no means an exhaustive test

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× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/football-preloader/football-loading.php:23

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Attributes that need to be fixed:
  • Screenshots: Please a description for screenshot #1 in football-preloader/assets to your readme.txt
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === football-preloader === )
You can take inspiration from this readme.txt

football-preloader/football-loading.php 92% from 13 tests

"Football Preloader" version 1.0's primary PHP file adds more information about the plugin and serves as the entry point for 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 ("football-preloader.php" instead of "football-loading.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
Success! There were no dangerous files found in this plugin80 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
CSS13055
PHP191225

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.00
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
2 PNG files occupy 0.29MB with 0.22MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
css/football.png263.58KB82.57KB▼ 68.67%
football.png30.43KB4.83KB▼ 84.11%