89% afiliados-de-amazon-lite

Code Review | Amazon affiliate lite Plugin

WordPress plugin Amazon affiliate lite Plugin scored89%from 54 tests.

About plugin

  • Plugin page: afiliados-de-amaz...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.9.0-4.9
  • WordPress version: 6.3.1
  • First release: Oct 5, 2018
  • Latest release: Oct 5, 2018
  • Number of updates: 4
  • Update frequency: N/A
  • Top authors: nestornoe (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /1,719 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.13MB] [CPU: ▼1.33ms] Passed 4 tests

A check of server-side resources used by Amazon affiliate lite Plugin
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.60 ▲0.1341.30 ▼8.15
Dashboard /wp-admin3.50 ▲0.1967.43 ▲16.24
Posts /wp-admin/edit.php3.54 ▲0.1850.41 ▲1.00
Add New Post /wp-admin/post-new.php6.00 ▲0.1188.25 ▼0.79
Media Library /wp-admin/upload.php3.34 ▲0.1135.79 ▲2.64

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 12 new files
Database: 1 new table, 6 new options
New tables
wp_Amazon_articulos_lite
New WordPress options
db_upgraded
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for Amazon affiliate lite Plugin
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,923 ▲15213.53 ▼0.918.14 ▲6.0442.21 ▼2.13
Dashboard /wp-admin2,211 ▲205.86 ▲0.05105.67 ▼8.8277.06 ▲34.34
Posts /wp-admin/edit.php2,109 ▲171.97 ▼0.0334.62 ▼2.9732.83 ▲0.05
Add New Post /wp-admin/post-new.php1,534 ▼023.09 ▲0.01736.80 ▲105.0454.84 ▼6.35
Media Library /wp-admin/upload.php1,402 ▲144.24 ▲0.0496.21 ▼2.0972.56 ▲27.15

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though no errors were found, this is by no means an exhaustive test

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
No output text or server-side errors detected on direct access of PHP files

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

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that need to be fixed:
  • Contributors: The plugin contributors field is missing
You can look at the official readme.txt

afiliados-de-amazon-lite/ADAL-core.php 92% from 13 tests

The main PHP script in "Amazon affiliate lite Plugin" version 1.0.0 is automatically included on every request by WordPress
Please take the time to fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("afiliados-de-amazon-lite.php" instead of "ADAL-core.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin1,615 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP514429979
CSS2603561
JavaScript17275

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.29
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%
Functions23
▷ Named functions23100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.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.01MB with 0.01MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/adaico.png3.27KB0.86KB▼ 73.81%
js/img/adaico_lite.png3.27KB0.86KB▼ 73.81%
img/amazon_prime.png6.87KB3.07KB▼ 55.33%