10% pau-accesibilidad-universal

Code Review | PAU, Plugin Accessibility Universal

WordPress plugin PAU, Plugin Accessibility Universal scored10%from 54 tests.

About plugin

  • Plugin page: pau-accesibilidad...
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.1.28+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8-5.2
  • WordPress version: 6.3.1
  • First release: Jun 10, 2019
  • Latest release: Jun 10, 2019
  • Number of updates: 2
  • Update frequency: every 5.5 days
  • Top authors: estudioinclusivo (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,214 total downloads

Benchmarks

Plugin footprint 58% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The following installer errors require your attention
  • Install procedure validation failed for this plugin
    • > Notice in wp-content/plugins/pau-accesibilidad-universal/admin/class-pau-admin.php+109
    Trying to access array offset on value of type bool

Server metrics [RAM: ▲0.03MB] [CPU: ▼9.25ms] Passed 4 tests

Analyzing server-side resources used by PAU, Plugin Accessibility Universal
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.42 ▼0.0524.09 ▼17.61
Dashboard /wp-admin3.38 ▲0.0350.91 ▼12.28
Posts /wp-admin/edit.php3.43 ▲0.0748.46 ▼1.96
Add New Post /wp-admin/post-new.php5.96 ▲0.0892.31 ▼5.14
Media Library /wp-admin/upload.php3.30 ▲0.0755.79 ▲22.78
PAU /wp-admin/admin.php?page=pau3.3339.18
Hot Spots UA /wp-admin/admin.php?page=pau-hot-spots3.6239.57
Suppliers /wp-admin/admin.php?page=pau-proveedores3.3237.00
About us /wp-admin/admin.php?page=pau-about-us3.3438.58
Settings /wp-admin/admin.php?page=pau-settings3.5036.47
Support /wp-admin/admin.php?page=pau-support3.3236.46
Help /wp-admin/admin.php?page=pau-help3.3239.30

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 197 new files
Database: 1 new table, 7 new options
New tables
wp_pau_hotspots
New WordPress options
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
pau_default_data
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for PAU, Plugin Accessibility Universal
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,484 ▲72320.93 ▲6.55144.39 ▲142.6651.55 ▲9.48
Dashboard /wp-admin2,276 ▲705.84 ▲0.9597.89 ▼8.9288.97 ▲48.77
Posts /wp-admin/edit.php2,155 ▲522.16 ▲0.1533.49 ▼6.6332.64 ▼4.08
Add New Post /wp-admin/post-new.php1,581 ▲4321.26 ▼1.95703.56 ▲47.8656.23 ▼2.70
Media Library /wp-admin/upload.php1,449 ▲494.15 ▼0.06113.89 ▲7.3987.91 ▲44.44
PAU /wp-admin/admin.php?page=pau1,0863.5944.3534.00
Hot Spots UA /wp-admin/admin.php?page=pau-hot-spots7,7163.5967.11118.93
Suppliers /wp-admin/admin.php?page=pau-proveedores1,1463.5244.7069.82
About us /wp-admin/admin.php?page=pau-about-us1,1323.5341.6180.40
Settings /wp-admin/admin.php?page=pau-settings1,8673.6746.4589.05
Support /wp-admin/admin.php?page=pau-support1,0553.5242.7662.22
Help /wp-admin/admin.php?page=pau-help1,0603.5342.6871.63

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Smoke test failed, please fix the following
    • > GET request to /wp-admin/admin.php?page=pau-hot-spots
    • > Notice in wp-content/plugins/pau-accesibilidad-universal/admin/partials/pau-hotspots-display.php+1177
    Undefined variable: enlPageTitle
    • > GET request to /wp-admin/admin.php?page=pau-hot-spots
    • > Notice in wp-content/plugins/pau-accesibilidad-universal/admin/partials/pau-hotspots-display.php+1181
    Undefined variable: urlFinal

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 fix the following items
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/pau-accesibilidad-universal/public/partials/pau-public-display.php
  • 13× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/pau-accesibilidad-universal/admin/partials/pau-settings-display.php:15
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/pau-accesibilidad-universal/admin/partials/pau-styles-display.php:16
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/pau-accesibilidad-universal/admin/partials/pau-import-export-display.php:32
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/pau-accesibilidad-universal/admin/partials/pau-auto-wcag-display.php:16
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/pau-accesibilidad-universal/admin/partials/pau-wcag-assistant-display.php:16
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/pau-accesibilidad-universal/admin/partials/pau-about-us-display.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function sanitize_text_field() in wp-content/plugins/pau-accesibilidad-universal/admin/partials/pau-hotspots-display.php:16
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/pau-accesibilidad-universal/admin/partials/pau-help-display.php:16
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/pau-accesibilidad-universal/admin/partials/pau-wordpress-display.php:16
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/pau-accesibilidad-universal/admin/partials/pau-support-display.php:16

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser issues were found

Optimizations

Plugin configuration 83% from 29 tests

readme.txt 88% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
These attributes need your attention:
  • Tags: There are too many tags (14 tag instead of maximum 10)
  • Screenshots: A description for screenshot #5 is required in pau-accesibilidad-universal/assets to your readme.txt
Please take inspiration from this readme.txt

pau-accesibilidad-universal/pau-plugin.php 77% from 13 tests

The principal PHP file in "PAU, Plugin Accessibility Universal" v. 1.0.0 is loaded by WordPress automatically on each request
Please take the time to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("pau-accesibilidad-universal.php" instead of "pau-plugin.php")
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 359 characters long)
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected32,765 lines of code in 95 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript212,8902,75611,773
CSS81,6635699,415
SVG25005,283
PHP331,5041,5304,414
PO File25768431,672
Markdown2510158
JSON30049
HTML1001

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity11.28
▷ Minimum class complexity1.00
▷ Maximum class complexity61.00
Average method complexity2.67
▷ Minimum method complexity1.00
▷ Maximum method complexity50.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes18
▷ Abstract classes15.56%
▷ Concrete classes1794.44%
▷ Final classes00.00%
Methods111
▷ Static methods1412.61%
▷ Public methods9787.39%
▷ Protected methods00.00%
▷ Private methods1412.61%
Functions5
▷ Named functions480.00%
▷ Anonymous functions120.00%
Constants12
▷ Global constants12100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
58 PNG files occupy 0.94MB with 0.65MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
multimedia/pau/react/panel/perfiles/personalizado.png23.63KB3.11KB▼ 86.85%
multimedia/pau/react/panel/general/lectura.png2.91KB1.49KB▼ 48.64%
admin/img/menus/pau.png54.60KB12.12KB▼ 77.80%
multimedia/pau/react/header/resetear.png3.32KB1.48KB▼ 55.49%
admin/img/menus/auto-wcagg.png40.77KB9.53KB▼ 76.62%