78% hkinfosoft-unbounce-to-gravity-form-integration

Code Review | Unbounce Gravity Forms

WordPress plugin Unbounce Gravity Forms scored78%from 54 tests.

About plugin

  • Plugin page: hkinfosoft-unboun...
  • Plugin version: 1.7
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.1
  • WordPress version: 6.3.1
  • First release: Mar 17, 2018
  • Latest release: Nov 24, 2022
  • Number of updates: 27
  • Update frequency: every 63.5 days
  • Top authors: hkispl (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

80+ active /2,053 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
Installer ran successfully

Server metrics [RAM: ▲0.00MB] [CPU: ▼1.60ms] Passed 4 tests

Analyzing server-side resources used by Unbounce Gravity Forms
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0035.10 ▼3.95
Dashboard /wp-admin3.31 ▲0.0045.32 ▲3.67
Posts /wp-admin/edit.php3.36 ▲0.0044.96 ▼2.31
Add New Post /wp-admin/post-new.php5.89 ▲0.0087.46 ▲3.15
Media Library /wp-admin/upload.php3.23 ▲0.0034.05 ▼3.30

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 13 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_recent-comments
u2g_plugin_version
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts

Browser metrics Passed 4 tests

A check of browser resources used by Unbounce Gravity Forms
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.28 ▼1.101.64 ▼0.0442.16 ▲1.00
Dashboard /wp-admin2,206 ▲205.85 ▲0.93109.25 ▼14.5941.10 ▼2.43
Posts /wp-admin/edit.php2,089 ▲111.99 ▼0.0338.61 ▼1.7835.31 ▼0.49
Add New Post /wp-admin/post-new.php1,520 ▼1323.01 ▼0.27665.47 ▲33.3457.98 ▼14.10
Media Library /wp-admin/upload.php1,388 ▲34.23 ▲0.00102.55 ▼6.1941.14 ▼1.90

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 50% from 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 0% from 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
Please fix the following items
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/hkinfosoft-unbounce-to-gravity-form-integration/lead-unbounce-to-gravity/index.php
  • 7× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/hkinfosoft-unbounce-to-gravity-form-integration/admin/admin_page_view.php:41
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/hkinfosoft-unbounce-to-gravity-form-integration/admin/U2gManageTable.php on line 8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/hkinfosoft-unbounce-to-gravity-form-integration/admin/admin_functions.php:6
    • > PHP Warning
      require_once(ABSPATHwp-admin/includes/class-wp-list-table.php): failed to open stream: No such file or directory in wp-content/plugins/hkinfosoft-unbounce-to-gravity-form-integration/admin/U2gManageTable.php on line 8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/hkinfosoft-unbounce-to-gravity-form-integration/admin/settings_option_page.php:15
    • > PHP Fatal error
      require_once(): Failed opening required 'ABSPATHwp-admin/includes/class-wp-list-table.php' (include_path='.:/usr/share/php') in wp-content/plugins/hkinfosoft-unbounce-to-gravity-form-integration/admin/U2gManageTable.php on line 8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/hkinfosoft-unbounce-to-gravity-form-integration/includes/core_functions.php:5

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 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
8 plugin tags: gravity form, unbounce to gravity forms, unbounce gravity forms, forms, gravity forms...

hkinfosoft-unbounce-to-gravity-form-integration/UnbounceGravityIntegration.php 92% from 13 tests

The entry point to "Unbounce Gravity Forms" version 1.7 is a PHP file that has certain tags in its header comment area
It is important to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("hkinfosoft-unbounce-to-gravity-form-integration.php" instead of "UnbounceGravityIntegration.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Good job! No executable or dangerous file extensions detected683 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP87998539
CSS1193134
JavaScript12010

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity7.00
▷ Minimum class complexity7.00
▷ Maximum class complexity7.00
Average method complexity1.86
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods7
▷ Static methods00.00%
▷ Public methods7100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions27
▷ Named functions27100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
2 PNG files occupy 0.09MB with 0.07MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/images/u2gf-icon-30.png2.79KB0.83KB▼ 70.35%
admin/images/u2gf_pro_banner.png92.59KB28.50KB▼ 69.22%