84% wc-delayed-orders

Code Review | Delayed Orders for WooCommerce

WordPress plugin Delayed Orders for WooCommerce scored84%from 54 tests.

About plugin

  • Plugin page: wc-delayed-orders
  • Plugin version: 1.0.1
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.7.2
  • WordPress version: 6.3.1
  • First release: Nov 18, 2020
  • Latest release: Jun 19, 2021
  • Number of updates: 5
  • Update frequency: every 42.6 days
  • Top authors: dimchtz (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /408 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲0.02MB] [CPU: ▼1.98ms] Passed 4 tests

A check of server-side resources used by Delayed Orders for WooCommerce
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0339.93 ▼0.78
Dashboard /wp-admin3.32 ▲0.0250.23 ▼0.84
Posts /wp-admin/edit.php3.44 ▲0.0846.56 ▼0.47
Add New Post /wp-admin/post-new.php5.90 ▲0.0292.57 ▲4.26
Media Library /wp-admin/upload.php3.25 ▲0.0233.13 ▼5.84

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 19 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_recent-posts
can_compress_scripts
widget_recent-comments
wcdo_settings
widget_theysaidso_widget

Browser metrics Passed 4 tests

An overview of browser requirements for Delayed Orders for WooCommerce
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,809 ▲7413.26 ▼1.041.69 ▲0.1444.04 ▼3.13
Dashboard /wp-admin2,218 ▲304.88 ▼1.15112.16 ▲8.3842.80 ▼0.03
Posts /wp-admin/edit.php2,098 ▲92.01 ▼0.0336.46 ▲1.0833.14 ▼3.74
Add New Post /wp-admin/post-new.php1,542 ▲2823.48 ▲5.94608.23 ▼125.4556.58 ▼10.72
Media Library /wp-admin/upload.php1,397 ▲184.24 ▲0.0698.24 ▼1.9342.86 ▼0.77

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 7 options
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • db_upgraded
    • wcdo_settings
    • widget_recent-comments
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though no errors were found, this is by no means 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
The following issues need your attention
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wcdo_count_unmarked_orders() in wp-content/plugins/wc-delayed-orders/templates/settings-tab.php:5

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
8 plugin tags: wc, woocommerce, orders, delayed, order...

wc-delayed-orders/delayed-orders-for-woocommerce.php 92% from 13 tests

"Delayed Orders for WooCommerce" version 1.0.1's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
The following require your attention:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("wc-delayed-orders.php" instead of "delayed-orders-for-woocommerce.php")

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
There were no executable files found in this plugin707 lines of code in 15 files:
LanguageFilesBlank linesComment linesLines of code
PHP13272297602
PO File1253266
CSS16039

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity12.20
▷ Minimum class complexity1.00
▷ Maximum class complexity34.00
Average method complexity2.23
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces2
Interfaces0
Traits0
Classes5
▷ Abstract classes00.00%
▷ Concrete classes5100.00%
▷ Final classes00.00%
Methods41
▷ Static methods37.32%
▷ Public methods3892.68%
▷ Protected methods00.00%
▷ Private methods37.32%
Functions6
▷ Named functions350.00%
▷ Anonymous functions350.00%
Constants9
▷ Global constants9100.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