78% hide-any-page

Code Review | Hide Any Page

WordPress plugin Hide Any Page scored78%from 54 tests.

About plugin

  • Plugin page: hide-any-page
  • Plugin version: 1.0.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.3.1
  • WordPress version: 6.3.1
  • First release: Sep 13, 2022
  • Latest release: Sep 25, 2023
  • Number of updates: 20
  • Update frequency: every 18.9 days
  • Top authors: loythegreat (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active /906 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.04MB] [CPU: ▼6.77ms] Passed 4 tests

Server-side resources used by Hide Any Page
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0334.12 ▼1.83
Dashboard /wp-admin3.36 ▲0.0145.11 ▼15.99
Posts /wp-admin/edit.php3.47 ▲0.1246.53 ▲2.38
Add New Post /wp-admin/post-new.php5.94 ▲0.0581.49 ▼9.29
Media Library /wp-admin/upload.php3.28 ▲0.0533.41 ▲0.02
Hide Any Page Settings /wp-admin/options-general.php?page=hide-any-page3.2527.66

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 4 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
hap_hideanypage_settings
db_upgraded

Browser metrics Passed 4 tests

A check of browser resources used by Hide Any Page
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲4714.10 ▼0.561.50 ▼0.0339.93 ▼0.54
Dashboard /wp-admin2,199 ▲195.54 ▼0.0380.97 ▼5.2540.03 ▼2.51
Posts /wp-admin/edit.php2,107 ▲282.04 ▲0.0534.99 ▼1.2632.26 ▼0.70
Add New Post /wp-admin/post-new.php1,529 ▲123.09 ▲0.22662.70 ▲5.1364.81 ▲8.84
Media Library /wp-admin/upload.php1,407 ▲104.20 ▼0.0093.25 ▼3.2944.53 ▼0.89
Hide Any Page Settings /wp-admin/options-general.php?page=hide-any-page8002.0024.4724.40

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • The uninstall procedure has failed, leaving 7 options in the database
    • hap_hideanypage_settings
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
These server-side errors were triggered
    • > GET request to /wp-admin/options-general.php?page=hide-any-page
    • > Notice in wp-content/plugins/hide-any-page/hide-any-page.php+252
    Undefined index: hap_hideanypage

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please take a closer look at the following
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'Walker_Page' not found in wp-content/plugins/hide-any-page/class-hap-page-walker.php:2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/hide-any-page/hide-any-page.php:298

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 93% from 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: remove page, hide page, hide pages

hide-any-page/hide-any-page.php 85% from 13 tests

This is the main PHP file of "Hide Any Page" version 1.0.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
You should first fix the following items:
  • Domain Path: The domain path folder does not exist ("/languages/")
  • Description: Keep the plugin description shorter than 140 characters (currently 210 characters long)

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
Success! There were no dangerous files found in this plugin187 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
PHP230121181
CSS1016

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity12.00
▷ Minimum class complexity4.00
▷ Maximum class complexity20.00
Average method complexity2.10
▷ Minimum method complexity1.00
▷ Maximum method complexity6.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods20
▷ Static methods315.00%
▷ Public methods20100.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

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