74% disable-blog

Code Review | Disable Blog

WordPress plugin Disable Blog scored74%from 54 tests.

About plugin

  • Plugin page: disable-blog
  • Plugin version: 0.5.3
  • PHP compatiblity: 7.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.2
  • WordPress version: 6.3.1
  • First release: Dec 24, 2014
  • Latest release: Apr 3, 2023
  • Number of updates: 66
  • Update frequency: every 45.8 days
  • Top authors: joshuadnelson (100%)

Code review

54 tests

User reviews

13 reviews

Install metrics

10,000+ active /146,019 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▼0.53MB] [CPU: ▼28.44ms] Passed 4 tests

An overview of server-side resources used by Disable Blog
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.76 ▲0.3038.05 ▼9.60
Dashboard /wp-admin3.48 ▲0.1739.63 ▼16.44
Posts /wp-admin/edit.php3.35 ▼0.0128.97 ▼20.76
Add New Post /wp-admin/post-new.php3.35 ▼2.5429.39 ▼66.96
Media Library /wp-admin/upload.php3.48 ▲0.2534.69 ▲0.09

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

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

Browser metrics Passed 4 tests

Disable Blog: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,149 ▼61213.91 ▼0.651.74 ▼0.4743.08 ▼4.19
Dashboard /wp-admin1,549 ▼6285.32 ▼0.3478.48 ▼19.7938.01 ▼7.81
Posts /wp-admin/edit.php1,959 ▼1412.15 ▲0.2040.61 ▲2.2936.76 ▲1.63
Add New Post /wp-admin/post-new.php1,475 ▼5322.61 ▼0.43647.04 ▼60.3252.01 ▼0.15
Media Library /wp-admin/upload.php1,365 ▼294.20 ▲0.0396.18 ▼19.7944.40 ▼4.11

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • This plugin has failed uninstalling correctly, leaving 22 files (0.18MB) in the plugin directory
    • (new file) CHANGELOG.md
    • (new file) assets/js/disable-blog-customizer.js
    • (new file) includes/class-disable-blog-activator.php
    • (new file) assets/js/disable-blog-admin.js
    • (new file) README.md
    • (new file) LICENSE.txt
    • (new file) disable-blog.php
    • (new file) assets/css/disable-blog-admin.css
    • (new file) includes/class-disable-blog-admin.php
    • (new file) includes/class-disable-blog-deactivator.php
    • ...
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • 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
Good news, no errors were detected

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
The following issues need your attention
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/disable-blog/uninstall.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
10 plugin tags: disable rest api, posts, disable feeds, feeds, disable blog...

disable-blog/disable-blog.php Passed 13 tests

The primary PHP file in "Disable Blog" version 0.5.3 is used by WordPress to initiate all plugin functionality
120 characters long description:
Go blog-less with WordPress. This plugin disables all blog-related functionality (by hiding, removing, and redirecting).

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
Everything looks great! No dangerous files found in this plugin1,703 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
PHP146411,7521,389
Markdown2520252
JavaScript221846
CSS12416

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.57
Average class complexity28.89
▷ Minimum class complexity1.00
▷ Maximum class complexity118.00
Average method complexity3.49
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes9
▷ Abstract classes00.00%
▷ Concrete classes9100.00%
▷ Final classes00.00%
Methods101
▷ Static methods98.91%
▷ Public methods8584.16%
▷ Protected methods00.00%
▷ Private methods1615.84%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG images were found in this plugin