84% gravity-forms-multi-currency

Code Review | Gravity Forms Multi Currency

WordPress plugin Gravity Forms Multi Currency scored84%from 54 tests.

About plugin

  • Plugin page: gravity-forms-mul...
  • Plugin version: 1.7.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.8.1
  • WordPress version: 6.3.1
  • First release: Dec 16, 2012
  • Latest release: Apr 9, 2014
  • Number of updates: 18
  • Update frequency: every 26.6 days
  • Top authors: ilanco (100%)

Code review

54 tests

User reviews

7 reviews

Install metrics

700+ active /11,391 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

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

An overview of server-side resources used by Gravity Forms Multi Currency
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0236.19 ▼5.38
Dashboard /wp-admin3.32 ▼0.0247.06 ▼18.36
Posts /wp-admin/edit.php3.37 ▲0.0245.78 ▼2.67
Add New Post /wp-admin/post-new.php5.90 ▲0.0280.02 ▼21.41
Media Library /wp-admin/upload.php3.24 ▲0.0233.03 ▼4.15

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Gravity Forms Multi Currency
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲2914.76 ▲0.471.84 ▼0.0644.11 ▼2.14
Dashboard /wp-admin2,209 ▲305.86 ▲0.97111.73 ▲2.5043.53 ▼3.65
Posts /wp-admin/edit.php2,089 ▼02.01 ▼0.0235.80 ▲2.1834.25 ▲2.26
Add New Post /wp-admin/post-new.php1,514 ▼1917.66 ▼5.59678.06 ▼11.5552.02 ▼2.97
Media Library /wp-admin/upload.php1,382 ▼34.29 ▲0.1195.53 ▼14.3040.73 ▼4.77

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 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
The following issues need your attention
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/gravity-forms-multi-currency/tpl/custom_form_settings.php:4

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 Passed 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
6 plugin tags: gravity form, gravity, currency, multiple, forms...

gravity-forms-multi-currency/gravity-forms-multi-currency.php Passed 13 tests

"Gravity Forms Multi Currency" version 1.7.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
36 characters long description:
Per form currency for Gravity Forms.

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
There were no executable files found in this plugin141 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PHP2369141

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity19.00
▷ Minimum class complexity19.00
▷ Maximum class complexity19.00
Average method complexity2.29
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods14
▷ Static methods17.14%
▷ Public methods964.29%
▷ Protected methods17.14%
▷ Private methods428.57%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG images were found in this plugin