89% site-health-manager

Code Review | Site Health Manager

WordPress plugin Site Health Manager scored 89% from 54 tests.

About plugin

  • Plugin page: site-health-manager
  • Plugin version: 1.1.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2-5.2
  • WordPress version: 6.3.1
  • First release: May 19, 2019
  • Latest release: Jun 20, 2019
  • Number of updates: 17
  • Update frequency: every 1.9 days
  • Top authors: ramiy (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

300+ active / 2,852 total downloads

Benchmarks

Plugin footprint 82% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

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

Server-side resources used by Site Health Manager
Please fix the following
  • CPU: Total CPU usage must kept under 500.00ms (currently 745.09ms on /wp-admin/tools.php?page=site-health-manager)
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0640.18 ▲2.22
Dashboard /wp-admin3.37 ▲0.0646.64 ▼0.87
Posts /wp-admin/edit.php3.42 ▲0.0647.53 ▲0.05
Add New Post /wp-admin/post-new.php5.95 ▲0.0690.27 ▼5.12
Media Library /wp-admin/upload.php3.29 ▲0.0637.70 ▲2.40
Site Health Manager /wp-admin/tools.php?page=site-health-manager4.00745.09

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
widget_recent-comments
widget_recent-posts
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

Site Health Manager: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲4713.27 ▼1.344.97 ▲2.6540.63 ▲0.87
Dashboard /wp-admin2,204 ▲165.83 ▲0.94101.24 ▼13.4339.62 ▼2.24
Posts /wp-admin/edit.php2,096 ▲72.02 ▲0.0239.73 ▲2.8536.09 ▲3.40
Add New Post /wp-admin/post-new.php1,531 ▲1723.13 ▲5.61646.23 ▼48.9954.18 ▼6.31
Media Library /wp-admin/upload.php1,392 ▲44.17 ▼0.0492.56 ▼20.5641.72 ▼4.51
Site Health Manager /wp-admin/tools.php?page=site-health-manager1,8602.0423.2734.07

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
  • This plugin does not fully uninstall, leaving 6 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP Passed 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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need to be fixed: You can take inspiration from this readme.txt

site-health-manager/site-health-manager.php Passed 13 tests

The main file in "Site Health Manager" v. 1.1.2 serves as a complement to information provided in readme.txt and as the entry point to the plugin
88 characters long description:
Control which status tests and what debug information appear in your Site Health screen.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected285 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP286234285

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity45.00
▷ Minimum class complexity45.00
▷ Maximum class complexity45.00
Average method complexity5.40
▷ Minimum method complexity1.00
▷ Maximum method complexity31.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods10
▷ Static methods00.00%
▷ Public methods880.00%
▷ Protected methods00.00%
▷ Private methods220.00%
Functions1
▷ Named functions1100.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
There are no PNG files in this plugin