72% accessibility-enabler

Code Review | Accessibility Enabler

WordPress plugin Accessibility Enabler scored72%from 54 tests.

About plugin

  • Plugin page: accessibility-ena...
  • Plugin version: 1.8.0
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-6.3
  • WordPress version: 6.3.1
  • First release: Feb 1, 2019
  • Latest release: Aug 3, 2023
  • Number of updates: 42
  • Update frequency: every 39.1 days
  • Top authors: hikeorders30 (100%)

Code review

54 tests

User reviews

7 reviews

Install metrics

300+ active /10,123 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

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

This is a short check of server-side resources used by Accessibility Enabler
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0236.55 ▼6.30
Dashboard /wp-admin3.32 ▼0.0241.05 ▼22.70
Posts /wp-admin/edit.php3.37 ▲0.0245.08 ▼1.47
Add New Post /wp-admin/post-new.php5.90 ▲0.0289.42 ▼9.38
Media Library /wp-admin/upload.php3.24 ▲0.0235.43 ▲3.85
Accessibility Enabler /wp-admin/options-general.php?page=a11y-enabler3.2530.03

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 22 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
can_compress_scripts
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Accessibility Enabler
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,829 ▲8314.80 ▲0.511.88 ▲0.1341.09 ▼2.24
Dashboard /wp-admin2,210 ▲225.81 ▼0.0694.90 ▼4.4041.98 ▼0.43
Posts /wp-admin/edit.php2,090 ▲41.99 ▼0.0440.31 ▲6.2733.90 ▼2.86
Add New Post /wp-admin/post-new.php1,536 ▲1723.16 ▲0.08652.91 ▼22.9352.54 ▼13.36
Media Library /wp-admin/upload.php1,395 ▲44.19 ▲0.0194.99 ▼4.0641.23 ▼2.91
Accessibility Enabler /wp-admin/options-general.php?page=a11y-enabler9002.0121.4432.47

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded

Smoke tests 25% 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
    • > GET request to /wp-admin/options-general.php?page=a11y-enabler
    • > Notice in wp-content/plugins/accessibility-enabler/admin/partials/plugin-a11y-enabler-display.php+69
    Trying to access array offset on value of type bool

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/accessibility-enabler/public/partials/a11y-enabler-public-display.php
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/accessibility-enabler/admin/partials/plugin-a11y-enabler-display.php:18

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 90% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need your attention:
  • Tags: Please reduce the number of tags, currently 27 tag instead of maximum 10
Please take inspiration from this readme.txt

accessibility-enabler/a11y-enabler.php 85% from 13 tests

The main PHP script in "Accessibility Enabler" version 1.8.0 is automatically included on every request by WordPress
It is important to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("accessibility-enabler.php" instead of "a11y-enabler.php")
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected301 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP13208585295
JavaScript24546
CSS1040

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.09
Average class complexity1.75
▷ Minimum class complexity1.00
▷ Maximum class complexity4.00
Average method complexity1.20
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods30
▷ Static methods310.00%
▷ Public methods2583.33%
▷ Protected methods00.00%
▷ Private methods516.67%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
There were not PNG files found in your plugin