84% statsfc-match-centre

Code Review | StatsFC Match Centre

WordPress plugin StatsFC Match Centre scored 84% from 54 tests.

About plugin

  • Plugin page: statsfc-match-centre
  • Plugin version: 2.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-6.2.2
  • WordPress version: 6.3.1
  • First release: Nov 2, 2016
  • Latest release: Jun 22, 2023
  • Number of updates: 19
  • Update frequency: every 127.6 days
  • Top authors: willjw (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active / 1,480 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼6.72ms] Passed 4 tests

An overview of server-side resources used by StatsFC Match Centre
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0536.20 ▼5.32
Dashboard /wp-admin3.35 ▲0.0543.19 ▼5.56
Posts /wp-admin/edit.php3.40 ▲0.0445.94 ▼0.87
Add New Post /wp-admin/post-new.php5.93 ▲0.0484.11 ▼15.12
Media Library /wp-admin/upload.php3.27 ▲0.0437.24 ▲6.37

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for StatsFC Match Centre
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.66 ▼1.091.67 ▼0.1239.61 ▼8.06
Dashboard /wp-admin2,206 ▲155.83 ▼0.0895.76 ▼3.5940.20 ▼8.27
Posts /wp-admin/edit.php2,089 ▼02.03 ▼0.0040.46 ▲4.6534.29 ▼0.51
Add New Post /wp-admin/post-new.php1,533 ▼023.29 ▲0.07651.63 ▼0.4954.04 ▲3.06
Media Library /wp-admin/upload.php1,388 ▲34.15 ▼0.02109.40 ▲11.0647.70 ▲0.68

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 7 options
    • can_compress_scripts
    • widget_recent-posts
    • widget_statsfc_matchcentre
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget

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)
Good news, no errors were detected

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
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/statsfc-match-centre/statsfc-match-centre.php:40

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Please fix the following attributes:
  • Donate link: Invalid URI ("")
The official readme.txt is a good inspiration

statsfc-match-centre/statsfc-match-centre.php Passed 13 tests

The primary PHP file in "StatsFC Match Centre" version 2.0.1 is used by WordPress to initiate all plugin functionality
20 characters long description:
StatsFC Match Centre

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
Success! There were no dangerous files found in this plugin678 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript2785328
PHP14477189
CSS2351161

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity23.00
▷ Minimum class complexity23.00
▷ Maximum class complexity23.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods5
▷ Static methods120.00%
▷ Public methods5100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions2
▷ Named functions00.00%
▷ Anonymous functions2100.00%
Constants3
▷ Global constants3100.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
No PNG files were detected