79% easy-image-alternate-text

Code Review | Easy Image Alternate Text

WordPress plugin Easy Image Alternate Text scored79%from 54 tests.

About plugin

  • Plugin page: easy-image-altern...
  • Plugin version: 2.0.2
  • PHP compatiblity: 5.5+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-6.3
  • WordPress version: 6.3.1
  • First release: Jul 7, 2019
  • Latest release: Jul 22, 2023
  • Number of updates: 32
  • Update frequency: every 46.1 days
  • Top authors: seshelby (100%)

Code review

54 tests

User reviews

1 review

Install metrics

90+ active /1,619 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▼1.34ms] Passed 4 tests

An overview of server-side resources used by Easy Image Alternate Text
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0849.54 ▲5.45
Dashboard /wp-admin3.38 ▲0.0850.26 ▼6.47
Posts /wp-admin/edit.php3.50 ▲0.1453.23 ▲2.44
Add New Post /wp-admin/post-new.php5.97 ▲0.0896.56 ▼6.38
Media Library /wp-admin/upload.php3.31 ▲0.0837.57 ▲5.06

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

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

Browser metrics Passed 4 tests

Easy Image Alternate Text: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,837 ▲7614.37 ▼0.382.31 ▲0.1644.89 ▼1.29
Dashboard /wp-admin2,209 ▲295.67 ▼0.0187.40 ▼2.2941.82 ▼2.37
Posts /wp-admin/edit.php2,127 ▲272.03 ▼0.0140.99 ▼0.0039.50 ▲3.21
Add New Post /wp-admin/post-new.php1,549 ▼523.14 ▲4.69608.02 ▼21.2154.71 ▲6.05
Media Library /wp-admin/upload.php1,423 ▲234.23 ▲0.0297.01 ▼5.6350.75 ▲3.08

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Uninstall procedure validation failed for this plugin
    • > Notice in wp-content/plugins/easy-image-alternate-text/easy-image-alternate-text.php+44
    Undefined variable: blog_ids
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • 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
Even though everything seems fine, this is not an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Everything seems fine, however this is by no means an exhaustive test

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 issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Attributes that require attention:
  • Tags: There are too many tags (12 tag instead of maximum 10)
You can take inspiration from this readme.txt

easy-image-alternate-text/easy-image-alternate-text.php 92% from 13 tests

The primary PHP file in "Easy Image Alternate Text" version 2.0.2 is used by WordPress to initiate all plugin functionality
You should first fix the following items:
  • Description: Keep the plugin description shorter than 140 characters (currently 234 characters long)

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
No dangerous file extensions were detected340 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP181101288
JavaScript17038
CSS10114

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions26
▷ Named functions2388.46%
▷ Anonymous functions311.54%
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
PNG images were not found in this plugin