78% commenter-ignore-button

Code Review | Commenter Ignore Button

WordPress plugin Commenter Ignore Button scored78%from 54 tests.

About plugin

  • Plugin page: commenter-ignore-...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.1-4.7.1
  • WordPress version: 6.3.1
  • First release: Nov 11, 2016
  • Latest release: Nov 12, 2016
  • Number of updates: 11
  • Update frequency: every 6.4 days
  • Top authors: CK MacLeod (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /989 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully

Server metrics [RAM: ▲0.23MB] [CPU: ▲2.18ms] Passed 4 tests

Server-side resources used by Commenter Ignore Button
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.70 ▲0.2442.90 ▲4.66
Dashboard /wp-admin3.54 ▲0.2448.99 ▼4.73
Posts /wp-admin/edit.php3.65 ▲0.3054.26 ▲4.46
Add New Post /wp-admin/post-new.php6.12 ▲0.23100.25 ▲4.57
Media Library /wp-admin/upload.php3.46 ▲0.2339.76 ▲4.43
Commenter Ignore Button /wp-admin/options-general.php?page=cks_cib3.4335.24

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 34 new files
Database: no new tables, 9 new options
New WordPress options
widget_recent-comments
can_compress_scripts
cks_cib_options
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded
cks_cib_stylesheet_options
widget_recent-posts
cks_cib_version

Browser metrics Passed 4 tests

Commenter Ignore Button: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5814.79 ▲0.041.83 ▲0.1251.01 ▲4.59
Dashboard /wp-admin2,210 ▲224.85 ▼1.04110.80 ▼2.0041.69 ▼6.74
Posts /wp-admin/edit.php2,093 ▲42.04 ▲0.0441.05 ▲0.5038.14 ▼6.35
Add New Post /wp-admin/post-new.php1,536 ▼621.06 ▲2.61718.02 ▲11.6066.37 ▲5.21
Media Library /wp-admin/upload.php1,395 ▲104.23 ▲0.13109.28 ▼7.6854.09 ▲3.69
Commenter Ignore Button /wp-admin/options-general.php?page=cks_cib2,93016.22550.95162.25

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
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 0% 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
Almost there! Just fix the following items
  • 6× PHP files output text when accessed directly:
    • > /wp-content/plugins/commenter-ignore-button/cks_commenter_ignore_button.php
    • > /wp-content/plugins/commenter-ignore-button/cib-template-tags.php
    • > /wp-content/plugins/commenter-ignore-button/uninstall.php
    • > /wp-content/plugins/commenter-ignore-button/cib-settings.php
    • > /wp-content/plugins/commenter-ignore-button/cib-button.php
    • > /wp-content/plugins/commenter-ignore-button/cib-add-stylesheet.php
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function post_password_required() in wp-content/plugins/commenter-ignore-button/templates/comments.php:19

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
6 plugin tags: ignore commenter, community, trolls, comments, commenters...

commenter-ignore-button/cks_commenter_ignore_button.php 85% from 13 tests

The primary PHP file in "Commenter Ignore Button" version 1.0 is used by WordPress to initiate all plugin functionality
Please make the necessary changes and fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("commenter-ignore-button.php" instead of "cks_commenter_ignore_button.php")
  • Text Domain: The text domain should only use lowercase characters and dashes

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected2,514 lines of code in 13 files:
LanguageFilesBlank linesComment linesLines of code
PHP86243531,631
CSS3754701
JavaScript26133182

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 problems
Cyclomatic complexity
Average complexity per logical line of code0.25
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%
Functions62
▷ Named functions62100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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
6 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/ignore_unignore_dk.png1.26KB0.45KB▼ 64.40%
images/cib_plugin_signature.png3.98KB2.77KB▼ 30.37%
images/ignore_x.png1.69KB0.30KB▼ 82.42%
images/reply_arrow.png0.44KB0.27KB▼ 38.58%
images/cib-on-ignore-list.png11.72KB6.18KB▼ 47.28%