90% recent-orders-widget-for-woocommerce

Code Review | Recent Orders Widget for WooCommerce

WordPress plugin Recent Orders Widget for WooCommerce scored90%from 54 tests.

About plugin

  • Plugin page: recent-orders-wid...
  • Plugin version: 1.3.3
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3
  • WordPress version: 6.3.1
  • First release: Dec 20, 2021
  • Latest release: Sep 26, 2023
  • Number of updates: 10
  • Update frequency: every 64.5 days
  • Top authors: algoritmika (70%)wpcodefactory (40%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /1,011 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

Server-side resources used by Recent Orders Widget for WooCommerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0044.72 ▲0.35
Dashboard /wp-admin3.31 ▲0.0047.31 ▼6.61
Posts /wp-admin/edit.php3.36 ▲0.0044.57 ▼8.41
Add New Post /wp-admin/post-new.php5.89 ▲0.0082.85 ▼9.56
Media Library /wp-admin/upload.php3.23 ▲0.0038.13 ▲2.13

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 10 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Recent Orders Widget for WooCommerce
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.34 ▲0.051.69 ▼0.0546.51 ▲5.76
Dashboard /wp-admin2,198 ▲185.61 ▼0.0489.66 ▼9.3141.86 ▼0.68
Posts /wp-admin/edit.php2,100 ▼02.00 ▲0.0535.04 ▼6.5733.53 ▼7.64
Add New Post /wp-admin/post-new.php1,526 ▼223.42 ▲0.09653.95 ▼3.0865.41 ▲8.08
Media Library /wp-admin/upload.php1,397 ▼34.11 ▼0.07104.99 ▼4.4243.32 ▼5.87

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
The smoke test was a success, however most plugin functionality was not tested

SRP Passed 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
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 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
5 plugin tags: orders, woo commerce, recent orders, woocommerce, order

recent-orders-widget-for-woocommerce/recent-orders-for-woocommerce.php 92% from 13 tests

The primary PHP file in "Recent Orders Widget for WooCommerce" version 1.3.3 is used by WordPress to initiate all plugin functionality
Please take the time to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("recent-orders-widget-for-woocommerce.php" instead of "recent-orders-for-woocommerce.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
There were no executable files found in this plugin484 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP785346484

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity6.00
▷ Minimum class complexity1.00
▷ Maximum class complexity13.00
Average method complexity1.86
▷ Minimum method complexity1.00
▷ Maximum method complexity10.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes116.67%
Methods35
▷ Static methods12.86%
▷ Public methods35100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.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