89% wp-disable-block-editor

Code Review | WP Disable Block Editor

WordPress plugin WP Disable Block Editor scored89%from 54 tests.

About plugin

  • Plugin page: wp-disable-block-...
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0+
  • WordPress version: 6.3.1
  • First release: Nov 20, 2019
  • Latest release: May 26, 2023
  • Number of updates: 19
  • Update frequency: every 67.5 days
  • Top authors: iihglobal (100%)

Code review

54 tests

User reviews

1 review

Install metrics

100+ active /1,490 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.02MB] [CPU: ▼3.47ms] Passed 4 tests

This is a short check of server-side resources used by WP Disable Block Editor
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0244.19 ▼0.92
Dashboard /wp-admin3.32 ▲0.0251.85 ▼2.01
Posts /wp-admin/edit.php3.38 ▲0.0251.98 ▼2.96
Add New Post /wp-admin/post-new.php5.90 ▲0.02101.86 ▼8.00
Media Library /wp-admin/upload.php3.25 ▲0.0240.26 ▲2.67
WP Disable Gutenberg /wp-admin/options-general.php?page=WP_Disable_Gutenberg3.2136.10

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 5 new files
Database: no new tables, 7 new options
New WordPress options
db_upgraded
widget_recent-comments
WP_Disable_Gutenberg
can_compress_scripts
widget_recent-posts
widget_theysaidso_widget
theysaidso_admin_options

Browser metrics Passed 4 tests

WP Disable Block Editor: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.31 ▲0.081.71 ▲0.0336.54 ▼9.57
Dashboard /wp-admin2,196 ▲195.60 ▼0.0989.47 ▼6.2240.08 ▼0.93
Posts /wp-admin/edit.php2,101 ▲11.97 ▼0.0336.20 ▼5.1735.02 ▼3.07
Add New Post /wp-admin/post-new.php1,557 ▲1218.30 ▼4.80630.53 ▼43.2561.16 ▼1.44
Media Library /wp-admin/upload.php1,407 ▲134.23 ▲0.01106.80 ▲10.5845.62 ▼1.29
WP Disable Gutenberg /wp-admin/options-general.php?page=WP_Disable_Gutenberg8092.0228.7172.53

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
These items require your attention
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests Passed 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 Passed 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 87% from 29 tests

readme.txt 88% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need your attention:
  • Requires at least: Invalid version format
  • Tested up to: Invalid version format
Please take inspiration from this readme.txt

wp-disable-block-editor/wp-disable-block.php 85% from 13 tests

"WP Disable Block Editor" version 1.0.1's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("wp-disable-block-editor.php" instead of "wp-disable-block.php")

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 plugin178 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP32427178

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.43
Average class complexity1.00
▷ Minimum class complexity1.00
▷ Maximum class complexity1.00
Average method complexity1.00
▷ Minimum method complexity1.00
▷ Maximum method complexity1.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
There were not PNG files found in your plugin