78% kt-accessibility-toolbar

Code Review | ===KT Accessibility toolbar

WordPress plugin ===KT Accessibility toolbar scored78%from 54 tests.

About plugin

  • Plugin page: kt-accessibility-...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4.2-5.7.2
  • WordPress version: 6.3.1
  • First release: Jul 7, 2021
  • Latest release: Jul 7, 2021
  • Number of updates: 3
  • Update frequency: N/A
  • Top authors: kuware (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /333 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.01MB] [CPU: ▼6.74ms] Passed 4 tests

This is a short check of server-side resources used by ===KT Accessibility toolbar
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0138.41 ▼3.32
Dashboard /wp-admin3.34 ▼0.0143.45 ▼15.80
Posts /wp-admin/edit.php3.39 ▲0.0345.96 ▲0.76
Add New Post /wp-admin/post-new.php5.92 ▲0.0382.78 ▼5.00
Media Library /wp-admin/upload.php3.26 ▲0.0334.02 ▼2.85
KT Accessibility Toolbar /wp-admin/options-general.php?page=accessibility3.2329.89

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 10 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for ===KT Accessibility toolbar
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲3314.74 ▲0.181.77 ▼0.0244.05 ▼0.30
Dashboard /wp-admin2,210 ▲224.88 ▼0.99104.45 ▼10.3638.98 ▼4.38
Posts /wp-admin/edit.php2,093 ▲42.05 ▼0.0135.88 ▼3.3132.97 ▼1.35
Add New Post /wp-admin/post-new.php1,517 ▲9317.75 ▼2.47653.07 ▲98.7256.09 ▲5.95
Media Library /wp-admin/upload.php1,395 ▲44.23 ▼0.0495.83 ▼9.3242.55 ▼4.96
KT Accessibility Toolbar /wp-admin/options-general.php?page=accessibility7972.0226.0823.82

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
It is recommended to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/kt-accessibility-toolbar/toolbar.php
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function is_user_logged_in() in wp-content/plugins/kt-accessibility-toolbar/toolbar.php:147

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 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that require attention: You can take inspiration from this readme.txt

kt-accessibility-toolbar/accessibility.php 85% from 13 tests

The main PHP file in "===KT Accessibility toolbar" ver. 1.0 adds more information about the plugin and also serves as the entry point for this plugin
Please make the necessary changes and fix the following:
  • Text Domain: The text domain follows the same naming rules as the plugin slug: lowercase characters and dashes
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("kt-accessibility-toolbar.php" instead of "accessibility.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
No dangerous file extensions were detected932 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
CSS214331
JavaScript2398306
PHP53724295

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity6.50
▷ Minimum class complexity5.00
▷ Maximum class complexity8.00
Average method complexity1.73
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods15
▷ Static methods426.67%
▷ Public methods15100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants5
▷ Global constants5100.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
No PNG files were detected