84% dintero-checkout-for-woocommerce

Code Review | Dintero Checkout for WooCommerce Payment Methods

WordPress plugin Dintero Checkout for WooCommerce Payment Methods scored84%from 54 tests.

About plugin

  • Plugin page: dintero-checkout-...
  • Plugin version: 1.9.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 6.1.0-6.4.1
  • WordPress version: 6.3.1
  • First release: Jun 2, 2022
  • Latest release: Nov 21, 2023
  • Number of updates: 38
  • Update frequency: every 14.2 days
  • Top authors: dintero (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active /7,061 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

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

A check of server-side resources used by Dintero Checkout for WooCommerce Payment Methods
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0134.23 ▼10.10
Dashboard /wp-admin3.31 ▼0.0351.13 ▼9.08
Posts /wp-admin/edit.php3.36 ▲0.0149.20 ▲0.18
Add New Post /wp-admin/post-new.php5.89 ▲0.0184.56 ▼7.93
Media Library /wp-admin/upload.php3.24 ▲0.0132.99 ▼1.23

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 51 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
db_upgraded
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Dintero Checkout for WooCommerce Payment Methods
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,815 ▲5314.67 ▲0.391.76 ▲0.1837.90 ▼6.35
Dashboard /wp-admin2,198 ▲215.61 ▼0.0793.44 ▼7.0443.76 ▲0.65
Posts /wp-admin/edit.php2,097 ▼62.01 ▼0.0839.62 ▼12.7037.02 ▼5.10
Add New Post /wp-admin/post-new.php1,526 ▼023.05 ▼0.34648.50 ▲15.3561.07 ▲10.73
Media Library /wp-admin/upload.php1,403 ▲34.21 ▲0.0296.24 ▼7.7342.59 ▲0.81

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

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please take a closer look at the following
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wc_get_template() in wp-content/plugins/dintero-checkout-for-woocommerce/templates/dintero-checkout-embedded.php:11
    • > PHP Notice
      Undefined variable: checkout in wp-content/plugins/dintero-checkout-for-woocommerce/templates/dintero-checkout-express.php on line 9
    • > PHP Fatal error
      Uncaught Error: Call to a member function is_registration_enabled() on null in wp-content/plugins/dintero-checkout-for-woocommerce/templates/dintero-checkout-express.php:9

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)
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Attributes that need to be fixed: Please take inspiration from this readme.txt

dintero-checkout-for-woocommerce/dintero-checkout-for-woocommerce.php 92% from 13 tests

This is the main PHP file of "Dintero Checkout for WooCommerce Payment Methods" version 1.9.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please take the time to fix the following:
  • Requires at least: The required version number did not match the one declared in readme.txt ("5.8.3" instead of "6.1.0")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Good job! No executable or dangerous file extensions detected3,705 lines of code in 43 files:
LanguageFilesBlank linesComment linesLines of code
PHP346471,7373,100
JavaScript56588547
CSS414458

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity12.90
▷ Minimum class complexity1.00
▷ Maximum class complexity51.00
Average method complexity2.93
▷ Minimum method complexity1.00
▷ Maximum method complexity20.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes31
▷ Abstract classes516.13%
▷ Concrete classes2683.87%
▷ Final classes00.00%
Methods194
▷ Static methods2512.89%
▷ Public methods17087.63%
▷ Protected methods199.79%
▷ Private methods52.58%
Functions20
▷ Named functions1365.00%
▷ Anonymous functions735.00%
Constants4
▷ Global constants4100.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
There are no PNG files in this plugin