78% hide-wordpress-bar

Code Review | Hide WordPress Bar

WordPress plugin Hide WordPress Bar scored78%from 54 tests.

About plugin

  • Plugin page: hide-wordpress-bar
  • Plugin version: 1.0.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-3.0.1
  • WordPress version: 6.3.1
  • First release: May 19, 2017
  • Latest release: May 20, 2017
  • Number of updates: 3
  • Update frequency: every 3.0 days
  • Top authors: digoribeiro (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /612 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
The plugin installed gracefully, with no errors

Server metrics [RAM: ▼0.01MB] [CPU: ▼4.50ms] Passed 4 tests

An overview of server-side resources used by Hide WordPress Bar
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0141.64 ▲4.96
Dashboard /wp-admin3.31 ▼0.0444.95 ▼15.13
Posts /wp-admin/edit.php3.36 ▲0.0044.74 ▼2.45
Add New Post /wp-admin/post-new.php5.89 ▲0.0083.57 ▼5.31
Media Library /wp-admin/upload.php3.23 ▲0.0035.15 ▲4.91

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 6 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
widget_theysaidso_widget
db_upgraded
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

Checking browser requirements for Hide WordPress Bar
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,996 ▲25014.02 ▼0.599.13 ▲7.5043.43 ▼0.15
Dashboard /wp-admin2,210 ▲194.91 ▼0.99108.45 ▲10.3042.85 ▲1.83
Posts /wp-admin/edit.php2,114 ▲462.24 ▲0.1840.27 ▲3.8538.59 ▲3.58
Add New Post /wp-admin/post-new.php1,428 ▼8619.53 ▲1.98548.33 ▼90.4539.55 ▼9.26
Media Library /wp-admin/upload.php1,401 ▲224.38 ▲0.17104.74 ▲4.7341.50 ▼5.49

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-posts
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
Even though everything seems fine, this is not an exhaustive test

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
Please fix the following
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/hide-wordpress-bar/views/btn-view.php
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/hide-wordpress-bar/hide-wordpress-bar.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/hide-wordpress-bar/class.hide-bar.php:5

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)
There were no browser issues found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
Please fix the following attributes: You can look at the official readme.txt

hide-wordpress-bar/hide-wordpress-bar.php Passed 13 tests

The main PHP script in "Hide WordPress Bar" version 1.0.0 is automatically included on every request by WordPress
112 characters long description:
Do you know that admin bar of wordpress admin you always wanted to hide? You can leave ... I'll hide it for you.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
No dangerous file extensions were detected139 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
CSS17061
JavaScript11041
PHP33937

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.10
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%
Methods1
▷ Static methods00.00%
▷ Public methods1100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.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