90% cashenvoy-woocommerce-payment-gateway

Code Review | CashEnvoy Woocommerce Payment Gateway

WordPress plugin CashEnvoy Woocommerce Payment Gateway scored90%from 54 tests.

About plugin

  • Plugin page: cashenvoy-woocomm...
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-3.9.1
  • WordPress version: 6.3.1
  • First release: Jul 21, 2014
  • Latest release: Jul 21, 2014
  • Number of updates: 4
  • Update frequency: every 0.5 days
  • Top authors: chemikawale (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /3,628 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.05MB] [CPU: ▼6.72ms] Passed 4 tests

Server-side resources used by CashEnvoy Woocommerce Payment Gateway
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0540.86 ▼0.97
Dashboard /wp-admin3.36 ▲0.0547.22 ▼11.22
Posts /wp-admin/edit.php3.41 ▲0.0548.36 ▼2.26
Add New Post /wp-admin/post-new.php5.94 ▲0.0587.87 ▼12.42
Media Library /wp-admin/upload.php3.28 ▲0.0538.62 ▲0.18

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for CashEnvoy Woocommerce Payment Gateway
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.61 ▲0.261.70 ▼0.1645.48 ▼1.75
Dashboard /wp-admin2,198 ▲185.58 ▼0.0294.76 ▼3.2841.27 ▼4.78
Posts /wp-admin/edit.php2,100 ▲31.99 ▼0.0240.24 ▼0.0136.08 ▼1.30
Add New Post /wp-admin/post-new.php1,526 ▼923.07 ▲4.65681.09 ▲24.7355.78 ▼15.67
Media Library /wp-admin/upload.php1,400 ▼04.21 ▼0.0096.45 ▼19.6744.31 ▼4.50

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
It is recommended to fix the following
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-posts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

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 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
7 plugin tags: interswitch, cashenvoy, payment gateways, verve cards, woocommerce...

cashenvoy-woocommerce-payment-gateway/cashenvoy-woocommerce-payment-gateway.php 92% from 13 tests

"CashEnvoy Woocommerce Payment Gateway" version 1.0.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please take the time to fix the following:
  • Description: Keep the plugin description shorter than 140 characters (currently 148 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Everything looks great! No dangerous files found in this plugin308 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP111168308

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity6.00
▷ Minimum class complexity6.00
▷ Maximum class complexity6.00
Average method complexity1.56
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods10
▷ Static methods00.00%
▷ Public methods10100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions7
▷ Named functions7100.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
1 PNG file occupies 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
img/cashenvoy.png6.21KB4.09KB▼ 34.07%