10% bosslist

Code Review | BossList

WordPress plugin BossList scored10%from 54 tests.

About plugin

  • Plugin page: bosslist
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.9
  • WordPress version: 6.3.1
  • First release: Dec 23, 2012
  • Latest release: Jun 15, 2014
  • Number of updates: 8
  • Update frequency: every 67.2 days
  • Top authors: The-Boss (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

10+ active /1,812 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
You still need to fix the following installer errors
  • The plugin cannot be installed
    • > Deprecated in wp-content/plugins/bosslist/boss-list.php+144
    Function create_function() is deprecated

Server metrics [RAM: ▼1.90MB] [CPU: ▼55.94ms] Passed 4 tests

A check of server-side resources used by BossList
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /2.06 ▼1.404.14 ▼33.72
Dashboard /wp-admin2.12 ▼1.185.60 ▼44.99
Posts /wp-admin/edit.php2.12 ▼1.245.70 ▼45.79
Add New Post /wp-admin/post-new.php2.12 ▼3.775.95 ▼99.26
Media Library /wp-admin/upload.php2.12 ▼1.115.97 ▼29.93
Add New /wp-admin/post-new.php?post_type=bosslist2.125.61
Lists /wp-admin/edit-tags.php?taxonomy=bl_lists&post_type=bosslist2.127.41
All /wp-admin/edit.php?post_type=bosslist2.126.18

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

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

Browser metrics Passed 4 tests

Checking browser requirements for BossList
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,823 ▲3714.42 ▲0.051.74 ▼0.1047.42 ▲6.28
Dashboard /wp-admin2,229 ▲495.57 ▼0.0885.02 ▼2.9567.87 ▲23.36
Posts /wp-admin/edit.php2,134 ▲341.98 ▲0.0236.37 ▲1.4236.45 ▼0.87
Add New Post /wp-admin/post-new.php1,708 ▲18022.29 ▼0.78646.60 ▲23.5948.50 ▼13.32
Media Library /wp-admin/upload.php1,428 ▲284.14 ▼0.08100.40 ▲2.3580.96 ▲36.55
Add New /wp-admin/post-new.php?post_type=bosslist2,2837.74167.31107.23
Lists /wp-admin/edit-tags.php?taxonomy=bl_lists&post_type=bosslist1,3112.2428.5931.67
All /wp-admin/edit.php?post_type=bosslist1,1421.9032.3030.41

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • Uninstall procedure had uncaught errors
    • > Deprecated in wp-content/plugins/bosslist/boss-list.php+144
    Function create_function() is deprecated
  • Zombie WordPress options were found after uninstall: 7 options
    • widget_boss_list_widget
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
These server-side errors were triggered
  • 4 occurences, only the last one shown
    • > GET request to /wp-admin/edit.php?post_type=bosslist
    • > POST request to /wp-admin/admin-ajax.php
    • > Deprecated in wp-content/plugins/bosslist/boss-list.php+144
    Function create_function() is deprecated

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
  • 2× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_admin() in wp-content/plugins/bosslist/boss-list.php:42
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bosslist/boss-list-admin.php:37

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Attributes that require attention:
  • Screenshots: Add an image for screenshot #1 (screenshot-1.jpg)
You can take inspiration from this readme.txt

bosslist/boss-list.php 77% from 13 tests

The main PHP script in "BossList" version 1.0 is automatically included on every request by WordPress
You should first fix the following items:
  • Text Domain: The text domain name must use dashes instead of underscores, and it must be lowercase
  • Domain Path: The domain path points to an invalid folder, "/langs/" does not exist
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("bosslist.php" instead of "boss-list.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
Everything looks great! No dangerous files found in this plugin207 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP28743207

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.30
Average class complexity11.00
▷ Minimum class complexity11.00
▷ Maximum class complexity11.00
Average method complexity3.50
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
boss-list.png0.55KB0.47KB▼ 13.06%