72% mail-to-all-comment

Code Review | Mail To All

WordPress plugin Mail To All scored72%from 54 tests.

About plugin

  • Plugin page: mail-to-all-comment
  • Plugin version: 1.5.3
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-4.6
  • WordPress version: 6.3.1
  • First release: Dec 22, 2012
  • Latest release: Aug 17, 2016
  • Number of updates: 17
  • Update frequency: every 78.5 days
  • Top authors: leniy (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /3,207 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▼1.59ms] Passed 4 tests

This is a short check of server-side resources used by Mail To All
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0440.68 ▲1.43
Dashboard /wp-admin3.35 ▲0.0449.38 ▼0.88
Posts /wp-admin/edit.php3.40 ▲0.0445.05 ▼1.66
Add New Post /wp-admin/post-new.php5.93 ▲0.0485.83 ▼5.25
Media Library /wp-admin/upload.php3.27 ▲0.0440.36 ▲1.72
群发邮件 /wp-admin/admin.php?page=Mail-To-All/mail.php3.2133.48
关于 /wp-admin/admin.php?page=Mail-To-All3.2330.65
初始化 /wp-admin/admin.php?page=Mail-To-All/init.php3.2132.01

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 10 new files
Database: no new tables, 11 new options
New WordPress options
qw_MTA_default_sub
widget_recent-comments
qw_MTA_subject
db_upgraded
can_compress_scripts
widget_theysaidso_widget
qw_MTA_content
qw_MTA_mail
widget_recent-posts
theysaidso_admin_options
...

Browser metrics Passed 4 tests

An overview of browser requirements for Mail To All
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,819 ▲5814.25 ▼0.121.76 ▲0.1136.83 ▼4.00
Dashboard /wp-admin2,225 ▲485.62 ▼0.1182.86 ▼6.5186.43 ▲41.87
Posts /wp-admin/edit.php2,130 ▲302.00 ▲0.0236.62 ▼0.0540.92 ▲2.51
Add New Post /wp-admin/post-new.php1,567 ▲4123.07 ▼0.05711.36 ▲19.2963.52 ▲3.17
Media Library /wp-admin/upload.php1,424 ▲214.23 ▲0.01112.57 ▲14.6779.27 ▲38.19
群发邮件 /wp-admin/admin.php?page=Mail-To-All/mail.php9292.1223.7862.91
关于 /wp-admin/admin.php?page=Mail-To-All8962.1922.9466.01
初始化 /wp-admin/admin.php?page=Mail-To-All/init.php8861.9924.8463.69

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Please fix the following server-side errors
    • > GET request to /wp-admin/admin.php?page=Mail-To-All/mail.php
    • > Notice in wp-content/plugins/mail-to-all-comment/mail-to-all.php+142
    Undefined index: baocuncaogao
    • > GET request to /wp-admin/admin.php?page=Mail-To-All/mail.php
    • > Notice in wp-content/plugins/mail-to-all-comment/mail-to-all.php+145
    Undefined index: chongxinhuoquyouxiangliebiao
    • > GET request to /wp-admin/admin.php?page=Mail-To-All/mail.php
    • > Notice in wp-content/plugins/mail-to-all-comment/mail-to-all.php+149
    Undefined index: fasong
    • > GET request to /wp-admin/admin.php?page=Mail-To-All/init.php
    • > Notice in wp-content/plugins/mail-to-all-comment/mail-to-all.php+53
    Undefined index: MTA_init_btn

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
Almost there! Just 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/mail-to-all-comment/inc/leniy_admin_menu.php:23
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/mail-to-all-comment/mail-to-all.php:13

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 fix the following browser errors
    • > GET request to /wp-admin/admin.php?page=Mail-To-All
    • > Network (severe)
    https://blog.leniy.org/mail-to-all.html - Failed to load resource: the server responded with a status of 404 ()

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes:
  • Screenshots: Please add images for these screenshots: #1 (screenshot-1.png), #2 (screenshot-2.png)
You can take inspiration from this readme.txt

mail-to-all-comment/mail-to-all.php 92% from 13 tests

Analyzing the main PHP file in "Mail To All" version 1.5.3
Please make the necessary changes and fix the following:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("mail-to-all-comment.php" instead of "mail-to-all.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Success! There were no dangerous files found in this plugin325 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP33588325

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.18
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions13
▷ Named functions13100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
6 PNG files occupy 0.07MB with 0.02MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
inc/leniy.png1.36KB1.79KB0.00%
inc/leniy-ico.png0.45KB0.61KB0.00%
icon.png0.68KB0.65KB▼ 3.74%
screenshot-2.png34.59KB11.43KB▼ 66.95%
screenshot-1.png33.86KB12.21KB▼ 63.93%