89% pay-with-ath-movil-woocommerce-gateway

Code Review | Pay with ATH Movil (WooCommerce payment gateway)

WordPress plugin Pay with ATH Movil (WooCommerce payment gateway) scored89%from 54 tests.

About plugin

  • Plugin page: pay-with-ath-movi...
  • Plugin version: 1.2.2
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-5.8
  • WordPress version: 6.3.1
  • First release: Apr 9, 2020
  • Latest release: Sep 30, 2022
  • Number of updates: 28
  • Update frequency: every 32.4 days
  • Top authors: robtorres (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

300+ active /2,854 total downloads

Benchmarks

Plugin footprint 83% 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.10MB] [CPU: ▼6.93ms] Passed 4 tests

Server-side resources used by Pay with ATH Movil (WooCommerce payment gateway)
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1043.35 ▲2.41
Dashboard /wp-admin3.40 ▲0.1052.74 ▲0.41
Posts /wp-admin/edit.php3.52 ▲0.1654.41 ▼7.05
Add New Post /wp-admin/post-new.php5.98 ▲0.1086.36 ▼20.72
Media Library /wp-admin/upload.php3.32 ▲0.1035.78 ▼0.34

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 51 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
db_upgraded
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by Pay with ATH Movil (WooCommerce payment gateway)
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,796 ▲3514.37 ▲0.141.78 ▲0.0243.24 ▲2.34
Dashboard /wp-admin2,205 ▲285.64 ▼0.0591.80 ▼0.3041.02 ▼2.91
Posts /wp-admin/edit.php2,110 ▲72.06 ▲0.0439.87 ▼7.7036.56 ▼4.51
Add New Post /wp-admin/post-new.php1,552 ▲2123.19 ▼0.02662.44 ▲29.1260.61 ▲5.82
Media Library /wp-admin/upload.php1,404 ▲74.32 ▲0.0599.52 ▼1.9644.77 ▲0.58

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
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Congratulations! This plugin passed the SRP 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 errors were detected

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 require attention:
  • Tags: There are too many tags (13 tag instead of maximum 10)
You can look at the official readme.txt

pay-with-ath-movil-woocommerce-gateway/woocommerce-gateway-athmovil.php 92% from 13 tests

The main PHP script in "Pay with ATH Movil (WooCommerce payment gateway)" version 1.2.2 is automatically included on every request by WordPress
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("pay-with-ath-movil-woocommerce-gateway.php" instead of "woocommerce-gateway-athmovil.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin437 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP110371383
PO File1222150
JavaScript3003
CSS1001

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.42
Average class complexity28.50
▷ Minimum class complexity11.00
▷ Maximum class complexity46.00
Average method complexity4.67
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods15
▷ Static methods16.67%
▷ Public methods15100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions6
▷ Named functions583.33%
▷ Anonymous functions116.67%
Constants7
▷ Global constants7100.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
6 PNG files occupy 0.04MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/theme_light.png4.05KB2.26KB▼ 44.28%
assets/images/icon.png17.05KB8.13KB▼ 52.30%
assets/images/theme_dark.png4.17KB2.34KB▼ 43.86%
assets/images/logo.png2.38KB1.74KB▼ 26.76%
assets/images/theme_default.png4.24KB2.04KB▼ 52.00%