73% woo-customers-manager

Code Review | Premmerce WooCommerce Customers Manager

WordPress plugin Premmerce WooCommerce Customers Manager scored73%from 54 tests.

About plugin

  • Plugin page: woo-customers-man...
  • Plugin version: 1.1.14
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.0-6.3
  • WordPress version: 6.3.1
  • First release: Sep 26, 2017
  • Latest release: Aug 11, 2023
  • Number of updates: 31
  • Update frequency: every 69.3 days
  • Top authors: premmerce (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

1,000+ active /23,994 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.53MB] [CPU: ▼0.28ms] 75% from 4 tests

A check of server-side resources used by Premmerce WooCommerce Customers Manager
The following require your attention
  • CPU: Total CPU usage should be kept under 500.00ms (currently 1,533.67ms on /wp-admin/admin.php?page=woo-customers-manager)
PageMemory (MB)CPU Time (ms)
Home /4.04 ▲0.5839.93 ▼4.33
Dashboard /wp-admin3.89 ▲0.5954.08 ▲1.07
Posts /wp-admin/edit.php3.94 ▲0.5953.72 ▲2.93
Add New Post /wp-admin/post-new.php6.41 ▲0.5399.61 ▲0.73
Media Library /wp-admin/upload.php3.66 ▲0.4340.73 ▲1.40
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius4.0240.14
Premmerce WooCommerce Customers Manager /wp-admin/admin.php?page=woo-customers-manager3.901,533.67

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

Input-output and database impact of this plugin
No storage issues were detected
Filesystem: 213 new files
Database: no new tables, 9 new options
New WordPress options
can_compress_scripts
fs_debug_mode
db_upgraded
fs_accounts
fs_active_plugins
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts

Browser metrics Passed 4 tests

This is an overview of browser requirements for Premmerce WooCommerce Customers Manager
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,838 ▲7714.21 ▼0.191.96 ▲0.2931.60 ▼15.44
Dashboard /wp-admin2,216 ▲425.61 ▼0.0290.51 ▼6.9445.46 ▼0.04
Posts /wp-admin/edit.php2,124 ▲242.11 ▲0.0840.66 ▲1.6539.91 ▲3.16
Add New Post /wp-admin/post-new.php1,537 ▲1123.22 ▼0.23660.18 ▼30.0756.87 ▲2.58
Media Library /wp-admin/upload.php1,424 ▲274.19 ▼0.09100.65 ▼2.2145.20 ▼0.34
Freemius Debug [v.2.5.10] /wp-admin/admin.php?page=freemius1,0721.6724.3531.59
Premmerce WooCommerce Customers Manager /wp-admin/admin.php?page=woo-customers-manager9801.8424.4357.87

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
These items require your attention
  • Uninstall procedure had uncaught errors
    • > Notice in wp-content/plugins/woo-customers-manager/freemius/includes/class-freemius.php+8486
    Undefined property: stdClass::$plugins
  • Zombie WordPress options were found after uninstall: 9 options
    • fs_debug_mode
    • db_upgraded
    • can_compress_scripts
    • widget_recent-comments
    • fs_active_plugins
    • widget_recent-posts
    • widget_theysaidso_widget
    • fs_accounts
    • theysaidso_admin_options

Smoke tests 75% from 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)
Even though everything seems fine, this is not an exhaustive test

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
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Interface 'Premmerce\\SDK\\V2\\Plugin\\PluginInterface' not found in wp-content/plugins/woo-customers-manager/src/ExtendedUsersPlugin.php:13
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/woo-customers-manager/custom-strings.php:7

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

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
3 plugin tags: customers, woocommerce customers, customers manager

woo-customers-manager/premmerce-extended-users.php 85% from 13 tests

"Premmerce WooCommerce Customers Manager" version 1.1.14's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
You should first fix the following items:
  • Requires at least: Required version does not match the one declared in readme.txt ("4.8" instead of "3.0.0")
  • Main file name: The principal plugin file should be the same as the plugin slug ("woo-customers-manager.php" instead of "premmerce-extended-users.php")

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
There were no executable files found in this plugin34,692 lines of code in 162 files:
LanguageFilesBlank linesComment linesLines of code
PHP1398,23217,78033,975
Markdown21210284
JavaScript33459194
PO File25868139
JSON20060
CSS145040

PHP code 50% from 2 tests

This is a very shot review of cyclomatic complexity and code structure
Please fix the following
  • Cyclomatic complexity of classes has to be reduced to less than 1000 (currently 3,073)
Cyclomatic complexity
Average complexity per logical line of code0.63
Average class complexity80.67
▷ Minimum class complexity1.00
▷ Maximum class complexity3,073.00
Average method complexity4.50
▷ Minimum method complexity1.00
▷ Maximum method complexity94.00
Code structure
Namespaces7
Interfaces1
Traits0
Classes56
▷ Abstract classes23.57%
▷ Concrete classes5496.43%
▷ Final classes00.00%
Methods1,333
▷ Static methods21816.35%
▷ Public methods93970.44%
▷ Protected methods171.28%
▷ Private methods37728.28%
Functions105
▷ Named functions9994.29%
▷ Anonymous functions65.71%
Constants150
▷ Global constants9865.33%
▷ Class constants5234.67%
▷ Public constants52100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
3 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
freemius/assets/img/plugin-icon.png9.16KB5.26KB▼ 42.58%
freemius/assets/img/theme-icon.png10.97KB5.78KB▼ 47.37%
freemius/assets/img/woo-customers-manager.png2.69KB1.38KB▼ 48.75%