83% gravity-forms-paystation-3-party-hosted

Code Review | Gravity Forms Paystation (3 Party Hosted)

WordPress plugin Gravity Forms Paystation (3 Party Hosted) scored83%from 54 tests.

About plugin

  • Plugin page: gravity-forms-pay...
  • Plugin version: 1.5.5
  • PHP version: 7.4.16
  • WordPress compatibility: 3.3-6.1
  • WordPress version: 6.3.1
  • First release: Mar 13, 2013
  • Latest release: Dec 12, 2022
  • Number of updates: 37
  • Update frequency: every 96.3 days
  • Top authors: paystationNZ (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

20+ active /4,641 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 gracefully, with no errors

Server metrics [RAM: ▲0.14MB] [CPU: ▼0.65ms] Passed 4 tests

Server-side resources used by Gravity Forms Paystation (3 Party Hosted)
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.59 ▲0.1242.67 ▼6.21
Dashboard /wp-admin3.45 ▲0.1452.70 ▲1.65
Posts /wp-admin/edit.php3.57 ▲0.2152.21 ▲4.78
Add New Post /wp-admin/post-new.php6.03 ▲0.1497.50 ▼2.83
Media Library /wp-admin/upload.php3.38 ▲0.1442.90 ▲4.88

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 14 new files
Database: no new tables, 7 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
gfpaystation_plugin
theysaidso_admin_options
can_compress_scripts
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for Gravity Forms Paystation (3 Party Hosted)
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,823 ▲6214.34 ▼0.071.96 ▲0.2638.68 ▼3.91
Dashboard /wp-admin2,207 ▲335.64 ▲0.0493.08 ▲1.9340.34 ▼0.16
Posts /wp-admin/edit.php2,113 ▲132.00 ▼0.0241.94 ▲4.6636.18 ▲1.60
Add New Post /wp-admin/post-new.php1,535 ▲922.98 ▼0.17682.27 ▼3.1366.31 ▲3.41
Media Library /wp-admin/upload.php1,412 ▲154.19 ▼0.12114.13 ▲13.9948.29 ▲2.06

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
Please fix the following items
  • The uninstall procedure has failed, leaving 7 options in the database
    • theysaidso_admin_options
    • gfpaystation_plugin
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 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
Please fix the following items
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/gravity-forms-paystation-3-party-hosted/class.GFPaystationPlugin.php:76

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser errors were detected

Optimizations

Plugin configuration 90% 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 require attention:
  • Tags: Please reduce the number of tags, currently 14 tag instead of maximum 10
The official readme.txt is a good inspiration

gravity-forms-paystation-3-party-hosted/gravityforms-paystation.php 85% from 13 tests

The main file in "Gravity Forms Paystation (3 Party Hosted)" v. 1.5.5 serves as a complement to information provided in readme.txt and as the entry point to the plugin
It is important to fix the following:
  • Description: The description should be shorter than 140 characters (currently 157 characters long)
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("gravity-forms-paystation-3-party-hosted.php" instead of "gravityforms-paystation.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Good job! No executable or dangerous file extensions detected1,579 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
PHP103968291,517
JavaScript1111939
CSS17123

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity16.92
▷ Minimum class complexity1.00
▷ Maximum class complexity76.00
Average method complexity3.69
▷ Minimum method complexity1.00
▷ Maximum method complexity20.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes13
▷ Abstract classes00.00%
▷ Concrete classes13100.00%
▷ Final classes00.00%
Methods77
▷ Static methods1215.58%
▷ Public methods6280.52%
▷ Protected methods1114.29%
▷ Private methods45.19%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants10
▷ Global constants990.00%
▷ Class constants110.00%
▷ Public constants1100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
images/paystation-32.png4.31KB1.57KB▼ 63.45%