68% send-users-email

Code Review | Send Users Email

WordPress plugin Send Users Email scored68%from 54 tests.

About plugin

  • Plugin page: send-users-email
  • Plugin version: 1.4.4
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.7-6.4.1
  • WordPress version: 6.3.1
  • First release: Oct 1, 2021
  • Latest release: Nov 14, 2023
  • Number of updates: 32
  • Update frequency: every 24.2 days
  • Top authors: metalfreek (100%)

Code review

54 tests

User reviews

22 reviews

Install metrics

4,000+ active /45,019 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲5.06MB] [CPU: ▲25.44ms] 75% from 4 tests

This is a short check of server-side resources used by Send Users Email
Please fix the following
  • Extra RAM: Extra memory usage should kept under 5MB (currently 5.06MB on /wp-admin/admin.php?page=freemius)
PageMemory (MB)CPU Time (ms)
Home /8.93 ▲5.4663.60 ▲24.78
Dashboard /wp-admin8.95 ▲5.6075.91 ▲15.78
Posts /wp-admin/edit.php8.95 ▲5.5981.79 ▲35.34
Add New Post /wp-admin/post-new.php9.47 ▲3.58122.95 ▲31.25
Media Library /wp-admin/upload.php8.95 ▲5.7266.53 ▲29.94
Email & Error Log /wp-admin/admin.php?page=send-users-email-error-logs8.9556.62
PRO Features /wp-admin/admin.php?page=send-users-email-pro-features8.9558.65
Dashboard /wp-admin/admin.php?page=send-users-email8.9566.33
Email Roles /wp-admin/admin.php?page=send-users-email-roles8.9565.88
Email Users /wp-admin/admin.php?page=send-users-email-users8.9564.35
Settings /wp-admin/admin.php?page=send-users-email-settings8.9558.54
Freemius Debug [v.2.6.0] /wp-admin/admin.php?page=freemius8.9558.05

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 226 new files
Database: no new tables, 9 new options
New WordPress options
widget_recent-posts
theysaidso_admin_options
can_compress_scripts
widget_recent-comments
fs_debug_mode
db_upgraded
fs_active_plugins
widget_theysaidso_widget
fs_accounts

Browser metrics Passed 4 tests

A check of browser resources used by Send Users Email
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,850 ▲10314.27 ▲0.151.62 ▼0.1927.74 ▼17.05
Dashboard /wp-admin2,252 ▲745.65 ▼0.0893.64 ▼22.6041.25 ▼3.16
Posts /wp-admin/edit.php2,161 ▲612.02 ▲0.0041.23 ▲3.0136.61 ▲1.61
Add New Post /wp-admin/post-new.php1,565 ▲3622.98 ▼0.19616.30 ▼32.5051.84 ▼0.52
Media Library /wp-admin/upload.php1,460 ▲574.22 ▲0.02100.42 ▼0.3942.85 ▲1.56
Email & Error Log /wp-admin/admin.php?page=send-users-email-error-logs8772.1433.3150.27
PRO Features /wp-admin/admin.php?page=send-users-email-pro-features9632.1133.8231.05
Dashboard /wp-admin/admin.php?page=send-users-email1,1512.1734.4438.07
Email Roles /wp-admin/admin.php?page=send-users-email-roles1,7887.09142.0460.91
Email Users /wp-admin/admin.php?page=send-users-email-users2,0997.44164.9450.53
Settings /wp-admin/admin.php?page=send-users-email-settings1,3182.2029.3229.52
Freemius Debug [v.2.6.0] /wp-admin/admin.php?page=freemius1,1281.6626.0629.42

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin cannot be uninstalled
    • > Notice in wp-content/plugins/send-users-email/vendor/freemius/includes/class-freemius.php+8546
    Undefined property: stdClass::$plugins
  • This plugin does not fully uninstall, leaving 9 options in the database
    • fs_active_plugins
    • can_compress_scripts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-posts
    • fs_accounts
    • fs_debug_mode
    • theysaidso_admin_options
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
These errors were triggered by the plugin
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=freemius
    • > request to
    • > Notice in wp-config.php+20
    Undefined index: REQUEST_METHOD

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
Please take a closer look at the following
  • 11× GET requests to PHP files have triggered server-side errors or warnings (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/send-users-email/admin/partials/templates/placeholder-instruction.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/send-users-email/partials/warnings.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/send-users-email/admin/partials/users-email.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/send-users-email/partials/toast.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function bloginfo() in wp-content/plugins/send-users-email/admin/partials/email-template.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/send-users-email/admin/partials/email_and_error_log.php:17
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/send-users-email/admin/partials/admin-pro-features.php:6
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/send-users-email/admin/partials/settings.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/send-users-email/partials/donate.php:22
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/send-users-email/admin/partials/roles-email.php:8

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
5 plugin tags: email all users, email users, send email, email subscribers, email system users

send-users-email/send-users-email.php Passed 13 tests

The main file in "Send Users Email" v. 1.4.4 serves as a complement to information provided in readme.txt and as the entry point to the plugin
80 characters long description:
Easily send emails to your users. Select individual users or role to send email.

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Everything looks great! No dangerous files found in this plugin37,064 lines of code in 164 files:
LanguageFilesBlank linesComment linesLines of code
PHP1418,41717,67236,367
JavaScript680108633
CSS16122348
XML13016

PHP code 50% from 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Please tend to the following items
  • Cyclomatic complexity of classes has to be reduced to less than 1000 (currently 3,096)
Cyclomatic complexity
Average complexity per logical line of code0.61
Average class complexity79.37
▷ Minimum class complexity1.00
▷ Maximum class complexity3,096.00
Average method complexity4.58
▷ Minimum method complexity1.00
▷ Maximum method complexity94.00
Code structure
Namespaces0
Interfaces1
Traits0
Classes58
▷ Abstract classes23.45%
▷ Concrete classes5696.55%
▷ Final classes00.00%
Methods1,320
▷ Static methods20515.53%
▷ Public methods91369.17%
▷ Protected methods171.29%
▷ Private methods39029.55%
Functions120
▷ Named functions120100.00%
▷ Anonymous functions00.00%
Constants149
▷ Global constants10268.46%
▷ Class constants4731.54%
▷ Public constants47100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
14 PNG files occupy 0.21MB with 0.14MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/twitter.png5.20KB1.85KB▼ 64.37%
assets/linkedin.png4.58KB1.43KB▼ 68.88%
assets/instagram.png11.52KB3.51KB▼ 69.56%
assets/facebook.png4.49KB1.56KB▼ 65.33%
assets/template.png40.74KB17.46KB▼ 57.13%