89% vellapay-payment-gateway

Code Review | VellaPay Payment Gateway

WordPress plugin VellaPay Payment Gateway scored89%from 54 tests.

About plugin

  • Plugin page: vellapay-payment-...
  • Plugin version: 1.0.5
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.2 or higher-6.0
  • WordPress version: 6.3.1
  • First release: Jun 9, 2022
  • Latest release: Jul 3, 2023
  • Number of updates: 8
  • Update frequency: every 48.6 days
  • Top authors: vellafinance (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /433 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼5.21ms] Passed 4 tests

An overview of server-side resources used by VellaPay Payment Gateway
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0141.34 ▼5.03
Dashboard /wp-admin3.32 ▲0.0147.99 ▼2.34
Posts /wp-admin/edit.php3.37 ▲0.0144.67 ▼0.87
Add New Post /wp-admin/post-new.php5.90 ▲0.0182.83 ▼12.58
Media Library /wp-admin/upload.php3.24 ▲0.0136.59 ▲1.70

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
can_compress_scripts
widget_theysaidso_widget
db_upgraded
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for VellaPay Payment Gateway
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,808 ▲6213.28 ▼1.311.62 ▼0.3043.14 ▼1.13
Dashboard /wp-admin2,214 ▲235.88 ▼0.02112.28 ▲10.0544.51 ▲3.42
Posts /wp-admin/edit.php2,096 ▲72.02 ▼0.0237.99 ▲1.3833.95 ▼2.11
Add New Post /wp-admin/post-new.php1,522 ▲817.71 ▲0.15658.46 ▼2.6851.73 ▼0.11
Media Library /wp-admin/upload.php1,396 ▲54.22 ▲0.0197.83 ▼4.2442.83 ▲1.93

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

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
Everything seems fine, however this is by no means an exhaustive test

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 83% from 29 tests

readme.txt 88% from 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
Attributes that require attention:
  • Tags: Too many tags (16 tag instead of maximum 10); only the first 5 tags are used in your directory listing
  • Requires at least: The plugin version is formatted incorrectly
You can look at the official readme.txt

vellapay-payment-gateway/woo-vella-pay.php 77% from 13 tests

The main PHP script in "VellaPay Payment Gateway" version 1.0.5 is automatically included on every request by WordPress
The following require your attention:
  • Requires at least: Required version number should only contain digits separated by dots (ex. "7.0" instead of "5.2 or higher")
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug
  • Main file name: Name the main plugin file the same as the plugin slug ("vellapay-payment-gateway.php" instead of "woo-vella-pay.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
No dangerous file extensions were detected834 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP2297361685
JavaScript1229115
SVG10026
CSS1108

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity100.00
▷ Minimum class complexity100.00
▷ Maximum class complexity100.00
Average method complexity5.50
▷ Minimum method complexity1.00
▷ Maximum method complexity30.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods22
▷ Static methods00.00%
▷ Public methods2090.91%
▷ Protected methods29.09%
▷ Private methods00.00%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.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
1 PNG file occupies 0.09MB with 0.05MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/vella-pay-icon.png94.55KB39.76KB▼ 57.95%