84% comment-approved-notifier-extended

Code Review | Comment Approved Notifier Extended

WordPress plugin Comment Approved Notifier Extended scored84%from 54 tests.

About plugin

  • Plugin page: comment-approved-...
  • Plugin version: 5.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3.1
  • WordPress version: 6.3.1
  • First release: Jan 20, 2015
  • Latest release: Sep 18, 2023
  • Number of updates: 95
  • Update frequency: every 33.3 days
  • Top authors: ufukart (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

500+ active /6,264 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
Installer ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼5.82ms] Passed 4 tests

An overview of server-side resources used by Comment Approved Notifier Extended
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0138.25 ▼3.96
Dashboard /wp-admin3.31 ▲0.0144.64 ▼4.49
Posts /wp-admin/edit.php3.37 ▲0.0147.57 ▲0.03
Add New Post /wp-admin/post-new.php5.90 ▲0.0185.92 ▼14.86
Media Library /wp-admin/upload.php3.24 ▲0.0133.14 ▲0.25

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 17 new files
Database: no new tables, 8 new options
New WordPress options
widget_recent-posts
cane_default_message_subject
db_upgraded
cane_default_message_body
can_compress_scripts
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

Comment Approved Notifier Extended: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,816 ▲8113.20 ▼1.101.83 ▼0.2743.39 ▼5.25
Dashboard /wp-admin2,219 ▲285.89 ▲0.99111.96 ▲7.0839.76 ▼1.01
Posts /wp-admin/edit.php2,108 ▲192.04 ▲0.0639.06 ▼1.0836.78 ▲1.88
Add New Post /wp-admin/post-new.php1,527 ▼317.70 ▼0.71655.59 ▲22.6151.15 ▼4.22
Media Library /wp-admin/upload.php1,404 ▲164.16 ▼0.1394.48 ▼5.1641.38 ▼3.31

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

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

SRP 50% 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
Almost there! Just fix the following items
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/comment-approved-notifier-extended/templates/email-template2.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function esc_html() in wp-content/plugins/comment-approved-notifier-extended/templates/email-template.php:4

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need to be fixed:
  • Screenshots: These screenshots require images: #1 (The plugin sends an TURKISH e-mail like that.), #2 (The plugin sends an ENGLISH e-mail like that.)
The official readme.txt might help

comment-approved-notifier-extended/comment-approved-notifier-extended.php Passed 13 tests

The main PHP script in "Comment Approved Notifier Extended" version 5.2 is automatically included on every request by WordPress
55 characters long description:
Send notification e-mail to user when comment approved.

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
No dangerous file extensions were detected1,461 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
CSS192411,054
PO File484119211
PHP31122196

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.13
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%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants00.00%
▷ Class constants2100.00%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
2 PNG files occupy 0.21MB with 0.15MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-2.png157.63KB23.58KB▼ 85.04%
screenshot-1.png55.25KB22.89KB▼ 58.58%