84% convertkit-gravity-forms

Code Review | Gravity Forms ConvertKit Add-On

WordPress plugin Gravity Forms ConvertKit Add-On scored84%from 54 tests.

About plugin

  • Plugin page: convertkit-gravit...
  • Plugin version: 1.4.0
  • PHP compatiblity: 5.6.20+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.4.1
  • WordPress version: 6.3.1
  • First release: Sep 10, 2015
  • Latest release: Nov 9, 2023
  • Number of updates: 39
  • Update frequency: every 76.5 days
  • Top authors: convertkit (64.1%)nathanbarry (33.33%)travisnorthcutt (5.13%)growdev (5.13%)

Code review

54 tests

User reviews

3 reviews

Install metrics

2,000+ active /45,774 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.24MB] [CPU: ▼4.01ms] Passed 4 tests

Server-side resources used by Gravity Forms ConvertKit Add-On
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.69 ▲0.2335.76 ▼6.94
Dashboard /wp-admin3.59 ▲0.2846.50 ▼4.39
Posts /wp-admin/edit.php3.64 ▲0.2851.00 ▼0.55
Add New Post /wp-admin/post-new.php6.11 ▲0.2295.95 ▼4.14
Media Library /wp-admin/upload.php3.45 ▲0.2236.42 ▲3.31

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
widget_recent-comments
theysaidso_admin_options
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Gravity Forms ConvertKit Add-On
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,815 ▲6814.20 ▲0.061.81 ▼0.0041.39 ▼1.78
Dashboard /wp-admin2,195 ▲185.60 ▲0.0191.87 ▼10.3738.83 ▼4.96
Posts /wp-admin/edit.php2,103 ▲31.94 ▼0.0841.17 ▲2.8134.84 ▲0.11
Add New Post /wp-admin/post-new.php1,526 ▼023.01 ▼0.33658.24 ▼12.8958.70 ▼0.40
Media Library /wp-admin/upload.php1,403 ▲94.17 ▼0.0595.58 ▼1.9539.80 ▼2.70

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Almost there! Just fix the following items
  • 4× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/convertkit-gravity-forms/vendor/convertkit/convertkit-wordpress-libraries/src/views/review-request.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_basename() in wp-content/plugins/convertkit-gravity-forms/convertkit.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'GFForms' not found in wp-content/plugins/convertkit-gravity-forms/includes/class-gfconvertkit.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'ConvertKit_API' not found in wp-content/plugins/convertkit-gravity-forms/includes/class-ckgf-api.php:15

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
5 plugin tags: embed form, marketing, convertkit, email, capture

convertkit-gravity-forms/convertkit.php 85% from 13 tests

"Gravity Forms ConvertKit Add-On" version 1.4.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please make the necessary changes and fix the following:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: Name the main plugin file the same as the plugin slug ("convertkit-gravity-forms.php" instead of "convertkit.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin2,172 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
PHP108511,9692,164
CSS1007
SVG1001

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.33
Average class complexity35.29
▷ Minimum class complexity4.00
▷ Maximum class complexity126.00
Average method complexity2.93
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods125
▷ Static methods21.60%
▷ Public methods9374.40%
▷ Protected methods00.00%
▷ Private methods3225.60%
Functions9
▷ Named functions777.78%
▷ Anonymous functions222.22%
Constants10
▷ Global constants10100.00%
▷ Class constants00.00%
▷ Public constants00.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 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
resources/backend/images/block-icon-form.png3.08KB3.08KB0.00%