84% woocommerce-admin-bar-addition

Code Review | WooCommerce Admin Bar Addition

WordPress plugin WooCommerce Admin Bar Addition scored84%from 54 tests.

About plugin

  • Plugin page: woocommerce-admin...
  • Plugin version: 2.7.0
  • PHP version: 7.4.16
  • WordPress version: 6.3.1
  • First release: Nov 30, 2011
  • Latest release: Feb 21, 2019
  • Number of updates: 68
  • Update frequency: every 38.8 days
  • Top authors: daveshine (100%)

Code review

54 tests

User reviews

15 reviews

Install metrics

2,000+ active /129,217 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.15MB] [CPU: ▼8.54ms] Passed 4 tests

This is a short check of server-side resources used by WooCommerce Admin Bar Addition
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.56 ▲0.1041.12 ▼1.98
Dashboard /wp-admin3.47 ▲0.1656.13 ▲6.62
Posts /wp-admin/edit.php3.58 ▲0.2248.76 ▼6.11
Add New Post /wp-admin/post-new.php6.05 ▲0.1688.11 ▼28.86
Media Library /wp-admin/upload.php3.39 ▲0.1636.37 ▲2.78

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for WooCommerce Admin Bar Addition
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,812 ▲4113.24 ▼1.441.79 ▼1.3144.50 ▲0.67
Dashboard /wp-admin2,212 ▲215.86 ▲0.80104.13 ▼15.8243.13 ▼9.95
Posts /wp-admin/edit.php2,095 ▲31.99 ▲0.0235.91 ▼6.2835.05 ▼2.25
Add New Post /wp-admin/post-new.php1,539 ▲2023.21 ▼0.24661.54 ▼6.3156.81 ▼7.73
Media Library /wp-admin/upload.php1,394 ▲94.27 ▲0.07103.63 ▼11.9941.07 ▼3.66

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • widget_theysaidso_widget
    • can_compress_scripts
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Even though everything seems fine, this is not an exhaustive test

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
  • 19× GET requests to PHP files return non-empty strings (only 10 are shown):
    • > /wp-content/plugins/woocommerce-admin-bar-addition/includes/wcaba-settings-v21x.php
    • > /wp-content/plugins/woocommerce-admin-bar-addition/includes/wcaba-wcbranding.php
    • > /wp-content/plugins/woocommerce-admin-bar-addition/includes/wcaba-shoplinks.php
    • > /wp-content/plugins/woocommerce-admin-bar-addition/includes/wcaba-plugins.php
    • > /wp-content/plugins/woocommerce-admin-bar-addition/woocommerce-admin-bar-addition.php
    • > /wp-content/plugins/woocommerce-admin-bar-addition/includes/wcaba-resources.php
    • > /wp-content/plugins/woocommerce-admin-bar-addition/includes/wcaba-functions.php
    • > /wp-content/plugins/woocommerce-admin-bar-addition/includes/wcaba-reports-v21x.php
    • > /wp-content/plugins/woocommerce-admin-bar-addition/includes/wcaba-plugins-compareproductspro.php
    • > /wp-content/plugins/woocommerce-admin-bar-addition/includes/wcaba-themes.php

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 88% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
These attributes need your attention:
  • Requires at least: Version not formatted correctly
  • Tags: Please delete some tags, you are using 14 tag instead of maximum 10
You can look at the official readme.txt

woocommerce-admin-bar-addition/woocommerce-admin-bar-addition.php Passed 13 tests

This is the main PHP file of "WooCommerce Admin Bar Addition" version 2.7.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
119 characters long description:
This plugin adds useful admin links and resources for the WooCommerce Shop Plugin to the WordPress Toolbar / Admin Bar.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin6,679 lines of code in 28 files:
LanguageFilesBlank linesComment linesLines of code
PO File71,6592,3693,549
PHP218441,2903,130

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.70
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions32
▷ Named functions32100.00%
▷ Anonymous functions00.00%
Constants12
▷ Global constants12100.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
7 compressed PNG files occupy 0.01MB
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/wcaba-icon-pink.png0.79KB0.77KB▼ 1.61%
images/wcaba-icon-grey.png0.61KB0.46KB▼ 25.91%
images/wcaba-icon-teal.png0.77KB0.75KB▼ 2.28%
images/wcaba-icon-orange.png0.78KB0.81KB0.00%
images/wcaba-icon-blue.png0.79KB0.79KB0.00%