90% vgc-for-givewp

Code Review | Very Good Collection Payment Gateway for GiveWP

WordPress plugin Very Good Collection Payment Gateway for GiveWP scored 90% from 54 tests.

About plugin

  • Plugin page: vgc-for-givewp
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.5-5.7.2
  • WordPress version: 6.3.1
  • First release: Jul 10, 2021
  • Latest release: Jul 10, 2021
  • Number of updates: 2
  • Update frequency: N/A
  • Top authors: wafsite (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 297 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▼0.68MB] [CPU: ▼19.01ms] Passed 4 tests

An overview of server-side resources used by Very Good Collection Payment Gateway for GiveWP
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0237.65 ▼3.77
Dashboard /wp-admin3.31 ▲0.0144.66 ▼5.66
Posts /wp-admin/edit.php3.36 ▲0.0147.47 ▼2.85
Add New Post /wp-admin/post-new.php3.13 ▼2.7638.71 ▼63.76
Media Library /wp-admin/upload.php3.24 ▲0.0134.55 ▲2.23

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_recent-posts
can_compress_scripts
db_upgraded
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for Very Good Collection Payment Gateway for GiveWP
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6514.44 ▲0.071.74 ▲0.0541.16 ▼7.85
Dashboard /wp-admin2,206 ▲185.90 ▲1.01107.12 ▼1.0140.54 ▲0.50
Posts /wp-admin/edit.php2,092 ▲32.02 ▼0.0438.92 ▼2.7633.95 ▲0.07
Add New Post /wp-admin/post-new.php1,514 ▼1417.74 ▼0.36583.89 ▼5.1850.08 ▼4.13
Media Library /wp-admin/upload.php1,388 ▼34.22 ▲0.0391.81 ▼8.6740.32 ▼4.88

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP Passed 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
Looking good! No server-side errors or output on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

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
4 plugin tags: donation, verygoodcollection, payment, givewp

vgc-for-givewp/vgc-givewp.php 92% from 13 tests

The main PHP script in "Very Good Collection Payment Gateway for GiveWP" version 1.0 is automatically included on every request by WordPress
The following require your attention:
  • Main file name: Name the main plugin file the same as the plugin slug ("vgc-for-givewp.php" instead of "vgc-givewp.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Everything looks great! No dangerous files found in this plugin303 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP16770303

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.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%
Functions8
▷ Named functions8100.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.02MB with 0.01MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/images/very-good-collection-logo.png17.02KB6.99KB▼ 58.91%