84% wpsimpletools-disable-comments

Code Review | Disable Comments

WordPress plugin Disable Comments scored 84% from 54 tests.

About plugin

  • Plugin page: wpsimpletools-dis...
  • Plugin version: 1.0.4
  • PHP compatiblity: 5.0.0+
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Jul 20, 2018
  • Latest release: Apr 14, 2021
  • Number of updates: 18
  • Update frequency: every 55.6 days
  • Top authors: wordpresssimpletools (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

10,000+ active / 20,325 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

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

This is a short check of server-side resources used by Disable Comments
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0139.41 ▼0.43
Dashboard /wp-admin3.32 ▲0.0148.20 ▼1.52
Posts /wp-admin/edit.php3.35 ▼0.0146.23 ▼2.29
Add New Post /wp-admin/post-new.php5.90 ▲0.0193.52 ▼0.22
Media Library /wp-admin/upload.php3.24 ▲0.0133.35 ▼1.00
All Comments /wp-admin/edit-comments.php3.0422.83

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
db_upgraded
widget_recent-posts
can_compress_scripts
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Disable Comments
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,780 ▲4513.28 ▼1.124.67 ▲2.8143.51 ▼5.10
Dashboard /wp-admin2,175 ▼134.86 ▼0.0297.92 ▼14.1744.45 ▲1.43
Posts /wp-admin/edit.php1,929 ▼1632.06 ▲0.0036.40 ▼1.8234.57 ▼0.19
Add New Post /wp-admin/post-new.php1,507 ▼723.20 ▲5.71623.31 ▼44.0151.51 ▼16.49
Media Library /wp-admin/upload.php1,360 ▼254.17 ▼0.0194.85 ▼0.4541.44 ▼4.33
All Comments /wp-admin/edit-comments.php2,1756.0286.8635.50

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/wpsimpletools-disable-comments/wpsimpletools-disable-comments.php

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)
There were no browser issues found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 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
4 plugin tags: disable comments, discussion, remove comments, comments

wpsimpletools-disable-comments/wpsimpletools-disable-comments.php Passed 13 tests

The main file in "Disable Comments" v. 1.0.4 serves as a complement to information provided in readme.txt and as the entry point to the plugin
69 characters long description:
Completely disables comments functionality from backend and frontend.

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
Good job! No executable or dangerous file extensions detected49 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP120849

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.17
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%
Functions8
▷ Named functions8100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
PNG images were not found in this plugin