84% woocommerce-basic-ordernumbers

Code Review | WooCommerce Basic Ordernumbers

WordPress plugin WooCommerce Basic Ordernumbers scored84%from 54 tests.

About plugin

  • Plugin page: woocommerce-basic...
  • Plugin version: 1.4.4
  • PHP version: 7.4.16
  • WordPress compatibility: 2.2-4.9.2
  • WordPress version: 6.3.1
  • First release: May 9, 2015
  • Latest release: Jan 29, 2018
  • Number of updates: 40
  • Update frequency: every 24.9 days
  • Top authors: opentools (100%)

Code review

54 tests

User reviews

1 review

Install metrics

500+ active /9,337 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▼0.00MB] [CPU: ▼12.09ms] Passed 4 tests

An overview of server-side resources used by WooCommerce Basic Ordernumbers
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0139.69 ▼4.53
Dashboard /wp-admin3.31 ▼0.0347.42 ▼14.99
Posts /wp-admin/edit.php3.36 ▲0.0145.47 ▼6.95
Add New Post /wp-admin/post-new.php5.89 ▲0.0187.13 ▼21.90
Media Library /wp-admin/upload.php3.23 ▲0.0137.36 ▲2.79

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

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

Browser metrics Passed 4 tests

WooCommerce Basic Ordernumbers: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,814 ▲2814.68 ▲0.331.80 ▼0.2140.33 ▼1.88
Dashboard /wp-admin2,192 ▲215.51 ▼0.0784.16 ▼9.4240.58 ▲0.31
Posts /wp-admin/edit.php2,100 ▼32.01 ▲0.0435.63 ▼3.6733.20 ▼2.71
Add New Post /wp-admin/post-new.php1,526 ▼023.06 ▼0.44665.68 ▼5.5360.61 ▼3.32
Media Library /wp-admin/upload.php1,400 ▼04.24 ▲0.0597.04 ▼10.4344.77 ▼1.03

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 2× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/woocommerce-basic-ordernumbers/library/ordernumber_helper.php
    • > /wp-content/plugins/woocommerce-basic-ordernumbers/ordernumber_helper_woocommerce.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
3 plugin tags: order numbers, orders, woocommerce

woocommerce-basic-ordernumbers/woocommerce-basic-ordernumbers.php 85% from 13 tests

The main PHP script in "WooCommerce Basic Ordernumbers" version 1.4.4 is automatically included on every request by WordPress
It is important to fix the following:
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug
  • Requires at least: Required version must be the same as the one declared in readme.txt ("4.0" instead of "2.2")

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
No dangerous file extensions were detected1,453 lines of code in 11 files:
LanguageFilesBlank linesComment linesLines of code
PHP41532961,022
JavaScript32236276
CSS32113154
HTML1001

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity36.33
▷ Minimum class complexity8.00
▷ Maximum class complexity68.00
Average method complexity2.18
▷ Minimum method complexity1.00
▷ Maximum method complexity19.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods90
▷ Static methods44.44%
▷ Public methods7077.78%
▷ Protected methods2022.22%
▷ Private methods00.00%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
5 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/advlogo100.png10.50KB4.97KB▼ 52.62%
library/images/loading.png17.69KB0.60KB▼ 96.58%
library/images/icon-16-edit.png0.61KB0.52KB▼ 14.61%
library/images/icon-16-delete.png0.54KB0.61KB0.00%
library/images/icon-16-new.png0.42KB0.37KB▼ 12.33%