84% bulk-plugin-toggle

Code Review | Bulk Plugin Toggle

WordPress plugin Bulk Plugin Toggle scored84%from 54 tests.

About plugin

  • Plugin page: bulk-plugin-toggle
  • Plugin version: 1.0.2
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-5.8
  • WordPress version: 6.3.1
  • First release: Jul 13, 2021
  • Latest release: Nov 27, 2021
  • Number of updates: 4
  • Update frequency: every 34.5 days
  • Top authors: coffee2code (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /469 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
Installer ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼7.01ms] Passed 4 tests

This is a short check of server-side resources used by Bulk Plugin Toggle
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0346.99 ▲4.03
Dashboard /wp-admin3.34 ▼0.0151.52 ▼16.18
Posts /wp-admin/edit.php3.39 ▲0.0351.47 ▼3.96
Add New Post /wp-admin/post-new.php5.92 ▲0.0393.71 ▼8.74
Media Library /wp-admin/upload.php3.26 ▲0.0337.95 ▲0.84

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Bulk Plugin Toggle
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲4314.72 ▲0.361.72 ▼0.5743.78 ▼5.21
Dashboard /wp-admin2,195 ▲185.61 ▼0.0592.99 ▼9.2142.83 ▼3.23
Posts /wp-admin/edit.php2,100 ▼32.02 ▲0.0041.02 ▲4.0836.55 ▼1.10
Add New Post /wp-admin/post-new.php1,526 ▼223.01 ▼0.07683.65 ▼24.4657.22 ▼12.38
Media Library /wp-admin/upload.php1,394 ▼34.29 ▲0.1697.36 ▼17.2343.97 ▼4.34

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Everything seems fine, however 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
Please fix the following items
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/bulk-plugin-toggle/tests/phpunit/bootstrap.php

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 Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
5 plugin tags: admin, plugins, coffee2code, toggle, bulk actions

bulk-plugin-toggle/bulk-plugin-toggle.php Passed 13 tests

The primary PHP file in "Bulk Plugin Toggle" version 1.0.2 is used by WordPress to initiate all plugin functionality
107 characters long description:
Adds "Toggle" as a bulk action for the plugins listing to toggle the activation state for selected plugins.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Everything looks great! No dangerous files found in this plugin440 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP4150178399
Markdown217027
XML10014

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity12.67
▷ Minimum class complexity1.00
▷ Maximum class complexity33.00
Average method complexity1.83
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods42
▷ Static methods1433.33%
▷ Public methods3992.86%
▷ Protected methods37.14%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
There are no PNG files in this plugin