84% comment-mention

Code Review | Comment Mention

WordPress plugin Comment Mention scored84%from 54 tests.

About plugin

  • Plugin page: comment-mention
  • Plugin version: 1.7.2
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-6.1.1
  • WordPress version: 6.3.1
  • First release: Oct 14, 2018
  • Latest release: Aug 10, 2023
  • Number of updates: 57
  • Update frequency: every 30.9 days
  • Top authors: bhargavbhandari90 (78.95%)hackkzy404 (22.81%)

Code review

54 tests

User reviews

4 reviews

Install metrics

200+ active /6,263 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▲0.12MB] [CPU: ▼3.39ms] Passed 4 tests

This is a short check of server-side resources used by Comment Mention
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.59 ▲0.1443.14 ▲1.96
Dashboard /wp-admin3.44 ▲0.0948.65 ▼12.01
Posts /wp-admin/edit.php3.55 ▲0.1945.81 ▼2.41
Add New Post /wp-admin/post-new.php6.02 ▲0.1383.62 ▼1.11
Media Library /wp-admin/upload.php3.36 ▲0.1340.50 ▲7.90

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 15 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts
db_upgraded
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for Comment Mention
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,835 ▲10013.21 ▼1.581.78 ▼0.1540.75 ▼3.46
Dashboard /wp-admin2,238 ▲525.87 ▲0.96108.95 ▼1.6442.57 ▼0.59
Posts /wp-admin/edit.php2,127 ▲382.01 ▲0.0136.54 ▲1.4232.09 ▼1.73
Add New Post /wp-admin/post-new.php1,561 ▲2823.25 ▲0.08690.20 ▼35.1352.67 ▼10.38
Media Library /wp-admin/upload.php1,423 ▲354.23 ▼0.0499.89 ▼1.8942.96 ▼2.37

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
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 applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/comment-mention/comment-mention.php:30

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that need to be fixed:
  • Screenshots: Please add images for these screenshots: #1 (Upload the plugin files to the `/wp-content/plugins/plugin-name` directory, or install the plugin through the WordPress plugins screen directly.), #2 (Activate the plugin through the 'Plugins' screen in WordPress), #3 (Use the Comment Mention menu to configure the plugin)
The official readme.txt might help

comment-mention/comment-mention.php Passed 13 tests

The primary PHP file in "Comment Mention" version 1.7.2 is used by WordPress to initiate all plugin functionality
68 characters long description:
Mention user in comments. Mentioned user will get email notification

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Everything looks great! No dangerous files found in this plugin862 lines of code in 12 files:
LanguageFilesBlank linesComment linesLines of code
PHP6257326705
Markdown146093
PO File1182159
JavaScript3003
CSS1002

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity25.67
▷ Minimum class complexity11.00
▷ Maximum class complexity43.00
Average method complexity3.90
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods22
▷ Static methods313.64%
▷ Public methods22100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions13
▷ Named functions1184.62%
▷ Anonymous functions215.38%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.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
2 PNG files occupy 0.16MB with 0.11MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png68.18KB20.75KB▼ 69.56%
screenshot-2.png97.65KB27.95KB▼ 71.38%