83% alt-attribute-audit

Code Review | Alt Attribute Audit

WordPress plugin Alt Attribute Audit scored83%from 54 tests.

About plugin

  • Plugin page: alt-attribute-audit
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-5.4.1
  • WordPress version: 6.3.1
  • First release: May 6, 2020
  • Latest release: May 6, 2020
  • Number of updates: 5
  • Update frequency: N/A
  • Top authors: thewatermethod (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /481 total downloads


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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.05MB] [CPU: ▼7.98ms] Passed 4 tests

Analyzing server-side resources used by Alt Attribute Audit
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0636.67 ▼1.81
Dashboard /wp-admin3.36 ▲0.0245.32 ▼17.07
Posts /wp-admin/edit.php3.47 ▲0.1245.22 ▼6.15
Add New Post /wp-admin/post-new.php5.94 ▲0.0587.73 ▼6.90
Media Library /wp-admin/upload.php3.28 ▲0.0536.51 ▲4.71
Alt Tags Audit /wp-admin/tools.php?page=edit_alt_tags3.2330.06

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 30 new files
Database: no new tables, 6 new options
New WordPress options

Browser metrics Passed 4 tests

Checking browser requirements for Alt Attribute Audit
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,820 ▲7414.47 ▲0.101.85 ▲0.1941.29 ▲2.16
Dashboard /wp-admin2,226 ▲415.87 ▲0.96106.57 ▲3.7438.78 ▼2.12
Posts /wp-admin/edit.php2,109 ▲202.02 ▼0.0341.05 ▲5.2436.09 ▲1.67
Add New Post /wp-admin/post-new.php1,533 ▲1923.19 ▲5.71662.06 ▲3.1171.46 ▲20.63
Media Library /wp-admin/upload.php1,408 ▲234.25 ▲0.03110.67 ▲11.1248.27 ▲5.22
Alt Tags Audit /wp-admin/tools.php?page=edit_alt_tags8132.2128.7922.83

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These errors were triggered by the plugin
    • > GET request to /wp-admin/tools.php?page=edit_alt_tags
    • > Deprecated in wp-includes/class-wp-hook.php+310
    Non-static method Wcw_Alt_Tag_Audit_Admin::render_options_page() should not be called statically

SRP Passed 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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected


Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
Attributes that require attention:
  • Plugin Name: Write the name of your plugin instead of "Plugin Name" on the first line ( === alt-attribute-audit === )
You can take inspiration from this readme.txt

alt-attribute-audit/wcw-alt-tag-audit.php 85% from 13 tests

The entry point to "Alt Attribute Audit" version 1.0.0 is a PHP file that has certain tags in its header comment area
Please take the time to fix the following:
  • 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
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("alt-attribute-audit.php" instead of "wcw-alt-tag-audit.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin565 lines of code in 18 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.22
Average class complexity3.67
▷ Minimum class complexity1.00
▷ Maximum class complexity14.00
Average method complexity1.62
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes00.00%
▷ Static methods519.23%
▷ Public methods2284.62%
▷ Protected methods00.00%
▷ Private methods415.38%
▷ Named functions3100.00%
▷ Anonymous functions00.00%
▷ 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
3 PNG files occupy 0.24MB with 0.13MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/screenshot-2.PNG24.11KB12.43KB▼ 48.44%
assets/screenshot-1.PNG219.21KB82.54KB▼ 62.35%
admin/app/public/favicon.png3.05KB1.47KB▼ 51.87%