72% convertkit

Code Review | ConvertKit - Email Marketing, Email Newsletter, Subscribers and Landing Pages

WordPress plugin ConvertKit - Email Marketing, Email Newsletter, Subscribers and Landing Pages scored72%from 54 tests.

About plugin

  • Plugin page: convertkit
  • Plugin version: 2.3.8
  • PHP compatiblity: 5.6.20+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.4.1
  • WordPress version: 6.3.1
  • First release: Mar 30, 2015
  • Latest release: Nov 20, 2023
  • Number of updates: 149
  • Update frequency: every 21.2 days
  • Top authors: convertkit (46.31%)nathanbarry (32.89%)travisnorthcutt (10.74%)ggwicz (5.37%)davidlamarwheeler (5.37%)

Code review

54 tests

User reviews

56 reviews

Install metrics

40,000+ active /2,103,128 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

Server metrics [RAM: ▲1.95MB] [CPU: ▲14.16ms] Passed 4 tests

Analyzing server-side resources used by ConvertKit - Email Marketing, Email Newsletter, Subscribers and Landing Pages
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /4.82 ▲1.3546.21 ▲5.47
Dashboard /wp-admin5.48 ▲2.1770.51 ▲18.94
Posts /wp-admin/edit.php5.54 ▲2.1872.03 ▲22.22
Add New Post /wp-admin/post-new.php8.07 ▲2.18110.37 ▲10.79
Media Library /wp-admin/upload.php5.34 ▲2.1157.51 ▲21.45
/wp-admin/admin.php?page=convertkit-setup5.2747.01
/wp-admin/admin.php?page=convertkit-restrict-content-setup5.1543.94
ConvertKit /wp-admin/options-general.php?page=_wp_convertkit_settings5.3154.49

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 183 new files
Database: no new tables, 8 new options
New WordPress options
widget_recent-comments
widget_convertkit_form
widget_recent-posts
widget_theysaidso_widget
convertkit_version
db_upgraded
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

ConvertKit - Email Marketing, Email Newsletter, Subscribers and Landing Pages: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,949 ▲18713.93 ▼0.787.79 ▲6.0238.64 ▼5.75
Dashboard /wp-admin2,259 ▲825.88 ▲0.24107.13 ▲11.5042.49 ▲0.03
Posts /wp-admin/edit.php2,187 ▲872.36 ▲0.4340.95 ▼0.7253.34 ▲20.91
Add New Post /wp-admin/post-new.php1,632 ▲10623.24 ▼0.12700.07 ▲106.3341.28 ▼12.76
Media Library /wp-admin/upload.php1,454 ▲544.42 ▲0.18100.72 ▲1.0042.46 ▲0.57
/wp-admin/admin.php?page=convertkit-setup3472.0929.1424.01
/wp-admin/admin.php?page=convertkit-restrict-content-setup280.410.103.59
ConvertKit /wp-admin/options-general.php?page=_wp_convertkit_settings1,0692.3332.7257.78

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 8 options
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • convertkit_version
    • widget_convertkit_form
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 25% 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
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/convertkit/views/backend/setup-wizard/close-modal.php
  • 72× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/convertkit/views/backend/post/quick-edit.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'ConvertKit_Resource' not found in wp-content/plugins/convertkit/includes/class-convertkit-resource-forms.php:15
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/convertkit/views/backend/tinymce/modal-field.php on line 9
    • > PHP Fatal error
      Uncaught Error: Class 'ConvertKit_Resource' not found in wp-content/plugins/convertkit/includes/class-convertkit-resource-landing-pages.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/convertkit/vendor/convertkit/convertkit-wordpress-libraries/src/views/review-request.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'ConvertKit_Elementor_Widget' not found in wp-content/plugins/convertkit/includes/integrations/elementor/class-convertkit-elementor-widget-form.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_attr() in wp-content/plugins/convertkit/views/frontend/restrict-content/product-email.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/convertkit/views/backend/post/meta-box.php:15
    • > PHP Warning
      Use of undefined constant ABSPATH - assumed 'ABSPATH' (this will throw an Error in a future version of PHP) in wp-content/plugins/convertkit/admin/class-multi-value-field-table.php on line 13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html_e() in wp-content/plugins/convertkit/views/backend/setup-wizard/convertkit-restrict-content-setup/content-1.php:11

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Please take a look at the following user-side issues
    • > GET request to /wp-admin/admin.php?page=convertkit-restrict-content-setup
    • > Network (severe)
    wp-admin/admin.php?page=convertkit-restrict-content-setup - Failed to load resource: the server responded with a status of 500 (Internal Server Error)

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
5 plugin tags: email marketing, subscribers, newsletter, email newsletter, membership

convertkit/wp-convertkit.php 92% from 13 tests

The main PHP script in "ConvertKit - Email Marketing, Email Newsletter, Subscribers and Landing Pages" version 2.3.8 is automatically included on every request by WordPress
It is important to fix the following:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("convertkit.php" instead of "wp-convertkit.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
There were no executable files found in this plugin13,788 lines of code in 174 files:
LanguageFilesBlank linesComment linesLines of code
PHP1144,1539,58010,947
JavaScript275059901,532
CSS15431171,071
JSON400180
SVG140058

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.31
Average class complexity13.99
▷ Minimum class complexity1.00
▷ Maximum class complexity126.00
Average method complexity2.59
▷ Minimum method complexity1.00
▷ Maximum method complexity24.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes78
▷ Abstract classes11.28%
▷ Concrete classes7798.72%
▷ Final classes00.00%
Methods628
▷ Static methods10.16%
▷ Public methods53485.03%
▷ Protected methods20.32%
▷ Private methods9214.65%
Functions43
▷ Named functions2660.47%
▷ Anonymous functions1739.53%
Constants16
▷ Global constants531.25%
▷ Class constants1168.75%
▷ Public constants11100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
6 PNG files occupy 0.26MB with 0.07MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
resources/backend/images/tag.png0.41KB0.28KB▼ 32.86%
resources/backend/images/block-example-formtrigger.png42.49KB44.07KB0.00%
resources/backend/images/block-example-product.png16.36KB18.00KB0.00%
resources/backend/images/members.png0.59KB0.38KB▼ 34.98%
resources/backend/images/block-example-form.png190.35KB50.34KB▼ 73.55%