83% kadence-woocommerce-email-designer

Code Review | Kadence WooCommerce Email Designer

WordPress plugin Kadence WooCommerce Email Designer scored83%from 54 tests.

About plugin

  • Plugin page: kadence-woocommer...
  • Plugin version: 1.5.12
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.6.0-6.3
  • WordPress version: 6.3.1
  • First release: May 29, 2018
  • Latest release: Nov 1, 2023
  • Number of updates: 76
  • Update frequency: every 26.1 days
  • Top authors: britner (100%)

Code review

54 tests

User reviews

133 reviews

Install metrics

100,000+ active /1,532,637 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
This plugin's installer ran successfully

Server metrics [RAM: ▲0.12MB] [CPU: ▼7.81ms] Passed 4 tests

A check of server-side resources used by Kadence WooCommerce Email Designer
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.59 ▲0.1336.82 ▼7.05
Dashboard /wp-admin3.44 ▲0.0944.43 ▼19.90
Posts /wp-admin/edit.php3.55 ▲0.1949.11 ▲4.34
Add New Post /wp-admin/post-new.php6.02 ▲0.1395.26 ▼0.70
Media Library /wp-admin/upload.php3.36 ▲0.1334.56 ▼3.60

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

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

Browser metrics Passed 4 tests

Checking browser requirements for Kadence WooCommerce Email Designer
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5414.35 ▼0.311.53 ▼0.2137.18 ▼9.78
Dashboard /wp-admin2,206 ▲285.62 ▼0.0989.69 ▼11.0841.26 ▼1.75
Posts /wp-admin/edit.php2,114 ▲141.99 ▲0.0140.60 ▲1.6737.50 ▲3.59
Add New Post /wp-admin/post-new.php1,532 ▲423.05 ▼0.02605.36 ▼87.4852.19 ▲2.18
Media Library /wp-admin/upload.php1,411 ▲114.20 ▼0.0798.22 ▼15.1844.98 ▼5.60

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
These items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • db_upgraded
    • widget_recent-comments
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP 50% 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
  • 2× 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/kadence-woocommerce-email-designer/kadence-woocommerce-email-designer.php:53
    • > PHP Fatal error
      Uncaught Error: Class 'Kadence_Woomail_Customizer' not found in wp-content/plugins/kadence-woocommerce-email-designer/templates/woo/emails/email-mobile-messaging.php:20

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
10 plugin tags: woocommerce, customizer, customize, mail, email design...

kadence-woocommerce-email-designer/kadence-woocommerce-email-designer.php 85% from 13 tests

The principal PHP file in "Kadence WooCommerce Email Designer" v. 1.5.12 is loaded by WordPress automatically on each request
It is important to fix the following:
  • Requires at least: Required version does not match the one declared in readme.txt ("5.3" instead of "5.6.0")
  • Description: The description should be shorter than 140 characters (currently 143 characters long)

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
No dangerous file extensions were detected23,967 lines of code in 74 files:
LanguageFilesBlank linesComment linesLines of code
PO File1542,650101,70815,186
PHP477842,3337,362
CSS56569847
JavaScript4111111478
XML10049
SVG20045

PHP code 50% from 2 tests

This is a very shot review of cyclomatic complexity and code structure
The following items need your attention
  • Cyclomatic complexity of methods should be reduced to less than 100 (currently 117)
Cyclomatic complexity
Average complexity per logical line of code0.48
Average class complexity38.47
▷ Minimum class complexity1.00
▷ Maximum class complexity171.00
Average method complexity5.45
▷ Minimum method complexity1.00
▷ Maximum method complexity117.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes15
▷ Abstract classes00.00%
▷ Concrete classes15100.00%
▷ Final classes00.00%
Methods125
▷ Static methods5846.40%
▷ Public methods11390.40%
▷ Protected methods00.00%
▷ Private methods129.60%
Functions6
▷ Named functions116.67%
▷ Anonymous functions583.33%
Constants3
▷ Global constants3100.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
48 compressed PNG files occupy 0.05MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/white/stumbleupon.png0.97KB0.84KB▼ 12.64%
assets/images/gray/stumbleupon.png1.16KB0.84KB▼ 27.48%
assets/images/black/tumblr.png0.71KB0.73KB0.00%
assets/images/black/whatsapp.png1.43KB1.49KB0.00%
assets/images/black/youtube.png1.28KB1.37KB0.00%