73% wc-product-customer-list

Code Review | Product Customer List for WooCommerce

WordPress plugin Product Customer List for WooCommerce scored73%from 54 tests.

About plugin

  • Plugin page: wc-product-custom...
  • Plugin version: 3.1.6
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0.0-6.3.1
  • WordPress version: 6.3.1
  • First release: Feb 18, 2016
  • Latest release: Oct 11, 2023
  • Number of updates: 151
  • Update frequency: every 18.5 days
  • Top authors: kokomoweb (100%)

Code review

54 tests

User reviews

69 reviews

Install metrics

10,000+ active /236,573 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲4.97MB] [CPU: ▲20.97ms] Passed 4 tests

Analyzing server-side resources used by Product Customer List for WooCommerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /8.87 ▲5.4066.93 ▲22.22
Dashboard /wp-admin8.89 ▲5.5875.77 ▲22.02
Posts /wp-admin/edit.php8.89 ▲5.5381.13 ▲32.09
Add New Post /wp-admin/post-new.php9.25 ▲3.36114.23 ▲7.55
Media Library /wp-admin/upload.php8.89 ▲5.6569.04 ▲35.19
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius8.8964.12

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 361 new files
Database: no new tables, 9 new options
New WordPress options
fs_accounts
fs_active_plugins
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts
fs_debug_mode
db_upgraded
widget_recent-comments
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Product Customer List for WooCommerce
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,809 ▲4814.28 ▲0.131.99 ▲0.3732.30 ▼9.41
Dashboard /wp-admin2,215 ▲435.63 ▼0.1492.02 ▼10.8645.76 ▲2.09
Posts /wp-admin/edit.php2,121 ▲212.15 ▲0.1936.91 ▲0.8139.66 ▲2.42
Add New Post /wp-admin/post-new.php1,534 ▲821.89 ▼1.12670.98 ▼5.9758.68 ▲5.49
Media Library /wp-admin/upload.php1,420 ▲204.24 ▲0.13102.73 ▼11.6550.30 ▲1.71
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius1,0721.6831.6930.84

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin did not uninstall without warnings or errors
    • > Notice in wp-content/plugins/wc-product-customer-list/freemius/includes/class-freemius.php+8486
    Undefined property: stdClass::$plugins
  • This plugin did not uninstall successfully, leaving 9 options in the database
    • fs_debug_mode
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • fs_accounts
    • db_upgraded
    • widget_recent-posts
    • fs_active_plugins
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Good news, no errors were detected

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Please fix the following
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wc-product-customer-list/views/legacy/table-customer-list-2-6.php:11
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/wc-product-customer-list/views/legacy/shortcodes-2-6.php:53
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wc-product-customer-list/functions.php:35

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% 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
Attributes that need to be fixed:
  • Tags: Please reduce the number of tags, currently 16 tag instead of maximum 10
The official readme.txt might help

wc-product-customer-list/wc-product-customer-list.php 92% from 13 tests

The entry point to "Product Customer List for WooCommerce" version 3.1.6 is a PHP file that has certain tags in its header comment area
Please take the time to fix the following:
  • Requires at least: The required version number did not match the one declared in readme.txt ("5.0" instead of "5.0.0")

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
Everything looks great! No dangerous files found in this plugin153,084 lines of code in 294 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript8525,07634,961109,021
PHP1358,43818,62638,306
CSS691312044,549
PO File2335404733
Sass3973475

PHP code 50% from 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
It is recommended to fix the following
  • Cyclomatic complexity of classes should be reduced to less than 1000 (currently 3,073)
Cyclomatic complexity
Average complexity per logical line of code0.62
Average class complexity83.85
▷ Minimum class complexity1.00
▷ Maximum class complexity3,073.00
Average method complexity4.57
▷ Minimum method complexity1.00
▷ Maximum method complexity94.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes59
▷ Abstract classes23.39%
▷ Concrete classes5796.61%
▷ Final classes00.00%
Methods1,377
▷ Static methods28320.55%
▷ Public methods98771.68%
▷ Protected methods171.23%
▷ Private methods37327.09%
Functions121
▷ Named functions11090.91%
▷ Anonymous functions119.09%
Constants148
▷ Global constants10168.24%
▷ Class constants4731.76%
▷ Public constants47100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
7 PNG files occupy 0.02MB with 0.00MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
freemius/assets/img/theme-icon.png10.97KB5.78KB▼ 47.37%
assets/vendor/datatables/datatables-1.10.24/images/sort_both.png0.20KB0.29KB0.00%
assets/vendor/datatables/datatables-1.10.24/images/sort_asc.png0.16KB0.25KB0.00%
freemius/assets/img/plugin-icon.png9.16KB5.26KB▼ 42.58%
assets/vendor/datatables/datatables-1.10.24/images/sort_desc_disabled.png0.14KB0.25KB0.00%