84% decoding-async

Code Review | image-auto-decoding-async

WordPress plugin image-auto-decoding-async scored84%from 54 tests.

About plugin

  • Plugin page: decoding-async
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.8.3-5.9
  • WordPress version: 6.3.1
  • First release: Jan 29, 2022
  • Latest release: Jan 29, 2022
  • Number of updates: 3
  • Update frequency: every 1.0 days
  • Top authors: dabohaze (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /309 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.00MB] [CPU: ▼1.55ms] Passed 4 tests

An overview of server-side resources used by image-auto-decoding-async
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0041.70 ▼1.11
Dashboard /wp-admin3.31 ▲0.0052.55 ▼3.17
Posts /wp-admin/edit.php3.36 ▲0.0051.54 ▼2.12
Add New Post /wp-admin/post-new.php5.89 ▲0.00101.17 ▲1.66
Media Library /wp-admin/upload.php3.23 ▲0.0037.37 ▲0.19

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for image-auto-decoding-async
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲314.68 ▲0.401.72 ▼0.8441.15 ▼5.01
Dashboard /wp-admin2,195 ▲155.63 ▼0.0191.12 ▼1.8639.51 ▼7.03
Posts /wp-admin/edit.php2,100 ▼02.00 ▲0.0134.96 ▼3.5234.45 ▼0.97
Add New Post /wp-admin/post-new.php1,529 ▲323.32 ▲0.30616.13 ▼79.0848.28 ▼7.72
Media Library /wp-admin/upload.php1,400 ▼04.18 ▼0.01101.80 ▼12.1746.57 ▼6.04

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
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Good news, no errors were detected

SRP 50% from 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
Please take a closer look at the following
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/decoding-async/image-auto-decoding-async.php:12

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
3 plugin tags: async, decoding, image

decoding-async/image-auto-decoding-async.php 92% from 13 tests

The main PHP file in "image-auto-decoding-async" ver. 1.0.0 adds more information about the plugin and also serves as the entry point for this plugin
It is important to fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("decoding-async.php" instead of "image-auto-decoding-async.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
Good job! No executable or dangerous file extensions detected6 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP11106

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.00
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%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
PNG images were not found in this plugin