90% rt-hide-posts-page-editor

Code Review | RT Hide Posts Page Editor

WordPress plugin RT Hide Posts Page Editor scored 90% from 54 tests.

About plugin

  • Plugin page: rt-hide-posts-pag...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.9
  • WordPress version: 6.3.1
  • First release: Oct 10, 2014
  • Latest release: Nov 21, 2017
  • Number of updates: 18
  • Update frequency: every 86.2 days
  • Top authors: roytanck (100%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active / 2,787 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.01MB] [CPU: ▼4.97ms] Passed 4 tests

An overview of server-side resources used by RT Hide Posts Page Editor
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0138.77 ▼4.42
Dashboard /wp-admin3.31 ▲0.0144.48 ▲0.35
Posts /wp-admin/edit.php3.37 ▲0.0147.80 ▲1.00
Add New Post /wp-admin/post-new.php5.90 ▲0.0181.91 ▼15.87
Media Library /wp-admin/upload.php3.24 ▲0.0137.30 ▲0.06

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 5 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
theysaidso_admin_options
db_upgraded
can_compress_scripts
widget_recent-posts
widget_recent-comments

Browser metrics Passed 4 tests

This is an overview of browser requirements for RT Hide Posts Page Editor
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲6513.15 ▼1.221.84 ▼0.1345.31 ▲0.54
Dashboard /wp-admin2,206 ▲154.88 ▲0.01108.27 ▲2.5640.19 ▼3.59
Posts /wp-admin/edit.php2,089 ▼02.00 ▼0.0240.22 ▼1.1036.76 ▲1.36
Add New Post /wp-admin/post-new.php1,539 ▼322.95 ▲4.81679.72 ▲20.6755.35 ▼2.13
Media Library /wp-admin/upload.php1,388 ▲34.21 ▲0.03109.55 ▼8.8647.67 ▼0.33

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test

SRP Passed 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
No output text or server-side errors detected on direct access of PHP files

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)
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
3 plugin tags: admin, editor, posts page

rt-hide-posts-page-editor/rt-hide-posts-page-editor.php Passed 13 tests

The entry point to "RT Hide Posts Page Editor" version 1.1 is a PHP file that has certain tags in its header comment area
77 characters long description:
Hides the content editor for the page that is set as the site's "posts page".

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Everything looks great! No dangerous files found in this plugin64 lines of code in 2 files:
LanguageFilesBlank linesComment linesLines of code
PO File15834
PHP1153730

PHP code Passed 2 tests

A brief analysis 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.58
Average class complexity5.00
▷ Minimum class complexity5.00
▷ Maximum class complexity5.00
Average method complexity2.00
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods4
▷ Static methods00.00%
▷ Public methods4100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.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
No PNG files were detected