78% visual-email-builder

Code Review | Drag and Drop Email Template Designer : Visual Email Builder

WordPress plugin Drag and Drop Email Template Designer : Visual Email Builder scored78%from 54 tests.

About plugin

  • Plugin page: visual-email-builder
  • Plugin version: 1.2
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.1
  • WordPress version: 6.3.1
  • First release: Feb 5, 2022
  • Latest release: Oct 26, 2022
  • Number of updates: 15
  • Update frequency: every 18.1 days
  • Top authors: wpmonks (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /1,042 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.09MB] [CPU: ▼7.64ms] Passed 4 tests

Analyzing server-side resources used by Drag and Drop Email Template Designer : Visual Email Builder
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0935.76 ▼6.27
Dashboard /wp-admin3.39 ▲0.0948.96 ▲4.54
Posts /wp-admin/edit.php3.45 ▲0.0950.10 ▼2.82
Add New Post /wp-admin/post-new.php6.06 ▲0.1785.42 ▼20.59
Media Library /wp-admin/upload.php3.32 ▲0.0934.07 ▼0.87
Licenses /wp-admin/edit.php?post_type=wpmnotifications&page=wpm_notification_licenses3.2829.87
Add New /wp-admin/post-new.php?post_type=wpmnotifications3.4643.90
All Notifications /wp-admin/edit.php?post_type=wpmnotifications3.3635.08

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 63 new files
Database: no new tables, 7 new options
New WordPress options
widget_theysaidso_widget
widget_recent-comments
db_upgraded
widget_recent-posts
stla_licenses
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

Drag and Drop Email Template Designer : Visual Email Builder: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,834 ▲9913.31 ▼1.071.83 ▲0.1141.65 ▼3.82
Dashboard /wp-admin2,231 ▲435.77 ▲0.87101.98 ▼11.0040.41 ▼1.26
Posts /wp-admin/edit.php2,123 ▲312.01 ▼0.0140.57 ▲1.1735.09 ▲1.04
Add New Post /wp-admin/post-new.php1,564 ▲3628.38 ▲10.09948.49 ▲318.9167.90 ▲16.59
Media Library /wp-admin/upload.php1,422 ▲404.20 ▼0.0599.55 ▲1.3141.88 ▼0.78
Licenses /wp-admin/edit.php?post_type=wpmnotifications&page=wpm_notification_licenses8072.0324.6825.58
Add New /wp-admin/post-new.php?post_type=wpmnotifications1,79910.54384.5648.45
All Notifications /wp-admin/edit.php?post_type=wpmnotifications1,0811.9531.1129.09

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
Please fix the following items
  • Zombie WordPress options were found after uninstall: 7 options
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • stla_licenses
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please take a closer look at the following
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/visual-email-builder/wpm-visual-notification-builder.php
  • 21× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/visual-email-builder/includes/emails/class-wpm-visual-wp-change-user-email-user.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/visual-email-builder/includes/emails/class-wpm-visual-wp-changed-user-email-user.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/visual-email-builder/includes/emails/class-wpm-visual-wp-lost-password-admin.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/visual-email-builder/includes/emails/class-wpm-visual-wp-download-personal-data-user.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/visual-email-builder/includes/emails/class-wpm-visual-wp-comment-in-moderation-admin.php:7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/visual-email-builder/includes/emails/class-wpm-visual-wp-automatic-core-update.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/visual-email-builder/includes/emails/class-wpm-visual-wp-changed-site-admin-email.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/visual-email-builder/includes/emails/class-wpm-visual-wp-password-changed-user.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/visual-email-builder/includes/emails/class-wpm-visual-wp-lost-password-user.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/visual-email-builder/includes/emails/class-wpm-visual-wp-change-site-admin-email.php:11

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

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
6 plugin tags: email templates, email builder, visual email builder, email editor, email designer...

visual-email-builder/wpm-visual-notification-builder.php 92% from 13 tests

"Drag and Drop Email Template Designer : Visual Email Builder" version 1.2's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
It is important to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("visual-email-builder.php" instead of "wpm-visual-notification-builder.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin2,329 lines of code in 47 files:
LanguageFilesBlank linesComment linesLines of code
PHP267586631,905
SVG111392
HTML150015
JavaScript32415
CSS2012

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity11.85
▷ Minimum class complexity1.00
▷ Maximum class complexity73.00
Average method complexity3.38
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes26
▷ Abstract classes00.00%
▷ Concrete classes26100.00%
▷ Final classes00.00%
Methods119
▷ Static methods1411.76%
▷ Public methods11294.12%
▷ Protected methods00.00%
▷ Private methods75.88%
Functions6
▷ Named functions350.00%
▷ Anonymous functions350.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
9 PNG files occupy 1.22MB with 0.56MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
includes/admin-menu/images/inactive.png1.58KB1.32KB▼ 16.60%
build/static/media/tracksmith.27668133.png362.99KB122.50KB▼ 66.25%
build/static/media/treehouse.48ca51ae.png49.88KB18.14KB▼ 63.62%
includes/admin-menu/images/active.png1.63KB1.34KB▼ 17.74%
build/static/media/whereby.275b62db.png69.00KB24.54KB▼ 64.44%