84% mail-queue

Code Review | Mail Queue

WordPress plugin Mail Queue scored84%from 54 tests.

About plugin

  • Plugin page: mail-queue
  • Plugin version: 1.3.1
  • PHP compatiblity: 7.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.9-6.4
  • WordPress version: 6.3.1
  • First release: Dec 29, 2021
  • Latest release: Nov 30, 2023
  • Number of updates: 47
  • Update frequency: every 14.9 days
  • Top authors: wdm-team (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /1,798 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.11MB] [CPU: ▼4.09ms] Passed 4 tests

Analyzing server-side resources used by Mail Queue
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0539.88 ▼2.10
Dashboard /wp-admin3.46 ▲0.1148.49 ▼14.11
Posts /wp-admin/edit.php3.57 ▲0.2150.86 ▲2.68
Add New Post /wp-admin/post-new.php6.04 ▲0.1594.67 ▼1.13
Media Library /wp-admin/upload.php3.38 ▲0.1533.74 ▲0.97
Settings /wp-admin/admin.php?page=wdm_wpma_mail_queue3.3530.26
FAQ /wp-admin/admin.php?page=wdm_wpma_mail_queue-tab-faq3.3533.55
Queue /wp-admin/admin.php?page=wdm_wpma_mail_queue-tab-queue3.3531.72
Log /wp-admin/admin.php?page=wdm_wpma_mail_queue-tab-log3.3531.39

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 10 new files
Database: 1 new table, 6 new options
New tables
wp_mail_queue
New WordPress options
widget_recent-posts
widget_recent-comments
theysaidso_admin_options
widget_theysaidso_widget
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

Checking browser requirements for Mail Queue
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,850 ▲10314.32 ▼0.021.65 ▼0.1845.64 ▲2.75
Dashboard /wp-admin2,258 ▲815.62 ▼0.0492.05 ▼5.7440.69 ▼0.91
Posts /wp-admin/edit.php2,164 ▲612.03 ▲0.0139.72 ▲1.6937.78 ▼1.66
Add New Post /wp-admin/post-new.php1,554 ▲1923.18 ▲0.16613.64 ▼82.5852.08 ▼5.26
Media Library /wp-admin/upload.php1,464 ▲644.19 ▲0.0297.67 ▼0.4440.89 ▼1.50
Settings /wp-admin/admin.php?page=wdm_wpma_mail_queue9942.1427.2736.19
FAQ /wp-admin/admin.php?page=wdm_wpma_mail_queue-tab-faq1,0402.0027.7056.99
Queue /wp-admin/admin.php?page=wdm_wpma_mail_queue-tab-queue9482.1724.8326.72
Log /wp-admin/admin.php?page=wdm_wpma_mail_queue-tab-log9422.0126.6725.67

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/mail-queue/mail-queue-options.php:16

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)
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Please fix the following attributes:
  • Screenshots: Add descriptions for screenshots #1, #2, #3, #4 in mail-queue/assets to your readme.txt
You can take inspiration from this readme.txt

mail-queue/mail-queue.php 92% from 13 tests

The main PHP file in "Mail Queue" ver. 1.3.1 adds more information about the plugin and also serves as the entry point for this plugin
Please make the necessary changes and fix the following:
  • Description: Please don't use more than 140 characters for the plugin description (currently 160 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Good job! No executable or dangerous file extensions detected813 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP212172746
CSS11040
SVG20017
JavaScript13110

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.34
Average class complexity41.00
▷ Minimum class complexity41.00
▷ Maximum class complexity41.00
Average method complexity6.71
▷ Minimum method complexity1.00
▷ Maximum method complexity20.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods7
▷ Static methods00.00%
▷ Public methods7100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions20
▷ Named functions20100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
No PNG images were found in this plugin