Benchmarks
Plugin footprint 82% from 16 tests
Installer Passed 1 test
🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors
Server metrics [RAM: ▲0.45MB] [CPU: ▲1,230.57ms] 50% from 4 tests
Analyzing server-side resources used by Smart Online Order for Clover
The following require your attention
- CPU: You should keep total CPU usage under 500.00ms (currently 2,789.91ms on /wp-admin/admin.php?page=moo_orders)
- Extra CPU: The extra CPU usage must be under 200.00ms (currently 1,230.57ms on /wp-admin/admin.php?page=moo_orders)
Page | Memory (MB) | CPU Time (ms) |
---|---|---|
Home / | 3.81 ▲0.35 | 42.40 ▲0.07 |
Dashboard /wp-admin | 3.86 ▲0.51 | 1,737.67 ▲1,674.69 |
Posts /wp-admin/edit.php | 3.86 ▲0.50 | 1,684.02 ▲1,634.50 |
Add New Post /wp-admin/post-new.php | 6.75 ▲0.86 | 1,748.30 ▲1,650.46 |
Media Library /wp-admin/upload.php | 3.66 ▲0.43 | 1,673.86 ▲1,637.24 |
Items / Images / Description /wp-admin/admin.php?page=moo_items | 4.03 | 2,543.38 |
Loyalty Dashboard /wp-admin/admin.php?page=moo_dashboard | 3.62 | 3,454.16 |
Reports /wp-admin/admin.php?page=moo_reports | 3.57 | 1,678.38 |
Store Interfaces /wp-admin/admin.php?page=moo_themes | 3.65 | 1,671.41 |
Settings /wp-admin/admin.php?page=moo_index | 3.79 | 1,673.45 |
Coupons /wp-admin/admin.php?page=moo_coupons | 3.75 | 2,394.39 |
Orders /wp-admin/admin.php?page=moo_orders | 3.64 | 2,789.91 |
Server storage [IO: ▲6.98MB] [DB: ▲0.02MB] Passed 3 tests
How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 245 new files
Database: 17 new tables, 12 new options
New tables |
---|
wp_moo_item_group |
wp_moo_tag |
wp_moo_order |
wp_moo_item_tax_rate |
wp_moo_item_order |
wp_moo_tax_rate |
wp_moo_modifier |
wp_moo_images |
wp_moo_order_types |
wp_moo_item_modifier_group |
... |
New WordPress options |
---|
can_compress_scripts |
moo_new_checkout_enabled |
moo_onlineOrders_version |
widget_recent-comments |
theysaidso_admin_options |
widget_moo_widget_oh |
db_upgraded |
widget_theysaidso_widget |
widget_recent-posts |
moo_settings |
... |
Browser metrics Passed 4 tests
Smart Online Order for Clover: an overview of browser usage
This plugin has a minimal impact on browser resources
Page | Nodes | Memory (MB) | Script (ms) | Layout (ms) |
---|---|---|---|---|
Home / | 3,195 ▲449 | 16.66 ▲2.19 | 14.68 ▲12.95 | 42.41 ▼1.13 |
Dashboard /wp-admin | 2,475 ▲298 | 7.03 ▲1.38 | 141.50 ▲44.22 | 38.46 ▼7.43 |
Posts /wp-admin/edit.php | 2,412 ▲312 | 4.64 ▲2.60 | 65.78 ▲26.02 | 92.85 ▲59.66 |
Add New Post /wp-admin/post-new.php | 1,822 ▲296 | 24.48 ▲0.82 | 680.90 ▲1.84 | 211.52 ▲151.03 |
Media Library /wp-admin/upload.php | 1,546 ▲149 | 5.87 ▲1.69 | 99.63 ▼4.25 | 96.22 ▲54.86 |
Items / Images / Description /wp-admin/admin.php?page=moo_items | 1,421 | 4.46 | 69.42 | 52.48 |
Loyalty Dashboard /wp-admin/admin.php?page=moo_dashboard | 267 | 12.23 | 352.81 | 51.98 |
Reports /wp-admin/admin.php?page=moo_reports | 800 | 2.84 | 32.20 | 18.39 |
Store Interfaces /wp-admin/admin.php?page=moo_themes | 1,262 | 4.58 | 68.69 | 97.91 |
Settings /wp-admin/admin.php?page=moo_index | 6,062 | 21.58 | 583.49 | 133.26 |
Coupons /wp-admin/admin.php?page=moo_coupons | 1,338 | 4.46 | 61.02 | 84.67 |
Orders /wp-admin/admin.php?page=moo_orders | 1,253 | 4.45 | 59.59 | 76.56 |
Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] 75% from 4 tests
🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
Please fix the following items
- This plugin does not fully uninstall, leaving 16 options in the database
- widget_recent-comments
- widget_theysaidso_widget
- moo_new_checkout_enabled
- moo_next_order_number
- db_upgraded
- moo_slug
- moo_pakms_key
- widget_moo_widget_oh
- can_compress_scripts
- theysaidso_admin_options
- ...
Smoke tests 0% from 4 tests
Server-side errors 0% from 1 test
🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These errors were triggered by the plugin
- > GET request to /wp-admin/admin.php?page=moo_coupons
- > Notice in wp-content/plugins/clover-online-orders/admin/includes/class-moo-coupons-list.php+63
Trying to get property 'elements' of non-object
- > GET request to /wp-admin/admin.php?page=moo_coupons
- > Notice in wp-content/plugins/clover-online-orders/admin/includes/class-moo-coupons-list.php+31
Trying to access array offset on value of type null
- 2 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=moo_orders
- > Notice in wp-content/plugins/clover-online-orders/admin/includes/class-moo-orders-list.php+33
Trying to access array offset on value of type bool
SRP 0% from 2 tests
🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following
- 1× PHP files perform the task of outputting text when accessed with GET requests:
- > /wp-content/plugins/clover-online-orders/admin/partials/moo-OnlineOrders-admin-display.php
- 2× GET requests to PHP files have triggered server-side errors or warnings:
- > PHP Fatal error
Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/clover-online-orders/includes/moo-OnlineOrders-widgets.php:13
- > PHP Fatal error
Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/clover-online-orders/includes/moo-OnlineOrders-Restapi.php:8
- > PHP Fatal error
User-side errors 0% from 1 test
🔹 Test weight: 20 | This is a shallow check for browser errors
There are user-side issues you should fix
- 6 occurences, only the last one shown
- > GET request to /wp-admin/admin.php?page=moo_orders
- > Console-api (warning) in unknown
https://maps.googleapis.com/maps/api/js?key=AIzaSyBv1TkdxvWkbFaDz2r0Yx7xvlNKe-2uyRc&libraries=drawing&geometry&ver=6.3.1 213:51 "Google Maps JavaScript API has been loaded directly without a callback. This is not supported and can lead to race conditions and suboptimal performance. For supported loading patterns please see https://goo.gle/js-api-loading"
- > GET request to /wp-admin/admin.php?page=moo_dashboard
- > Console-api (warning) in unknown
https://maps.googleapis.com/maps/api/js?key=AIzaSyBv1TkdxvWkbFaDz2r0Yx7xvlNKe-2uyRc 210:51 "Google Maps JavaScript API has been loaded directly without a callback. This is not supported and can lead to race conditions and suboptimal performance. For supported loading patterns please see https://goo.gle/js-api-loading"
- > GET request to /wp-admin/admin.php?page=moo_dashboard
- > Security (warning) in unknown
https://apis.google.com/_/scs/abc-static/_/js/k=gapi.lb.en.AOzoyjtjrhQ.O/m=auth2,client/rt=j/sv=1/d=1/ed=1/rs=AHpOoo9-fA1P7IZFa1fdRj158NoDqrnbYA/cb=gapi.loaded_0?le=scs 184 An iframe which has both allow-scripts and allow-same-origin for its sandbox attribute can escape its sandboxing.
- > GET request to /wp-admin/admin.php?page=moo_reports
- > Console-api (warning) in unknown
/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1 1:28609 "jQuery.Deferred exception: $(...).wpColorPicker is not a function" "TypeError: $(...).wpColorPicker is not a function\n at HTMLDocument.\u003Canonymous> (/wp-content/plugins/clover-online-orders/admin/js/moo-OnlineOrders-admin.js?ver=1.5.5:203:31)\n at e (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1:2:26990)\n at t (/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1:2:27292)" undefined
- > GET request to /wp-admin/admin.php?page=moo_reports
- > Javascript (severe) in unknown
/wp-admin/load-scripts.php?c=0&load%5Bchunk_0%5D=jquery-core,jquery-migrate,utils,moxiejs,plupload&ver=6.3.1 1:28721 Uncaught TypeError: $(...).wpColorPicker is not a function
Optimizations
Plugin configuration 90% from 29 tests
readme.txt 94% from 16 tests
The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need to be fixed:
- Screenshots: Add descriptions for screenshots #1, #10, #2, #3, #4, #5, #6, #7, #8, #9 in clover-online-orders/assets to your readme.txt
clover-online-orders/moo_OnlineOrders.php 85% from 13 tests
The principal PHP file in "Smart Online Order for Clover" v. 1.5.5 is loaded by WordPress automatically on each request
The following require your attention:
- Text Domain: The text domain name should consist of only dashes and lowercase characters
- Main file name: Name the main plugin file the same as the plugin slug ("clover-online-orders.php" instead of "moo_OnlineOrders.php")
Code Analysis 97% from 3 tests
File types Passed 1 test
🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Good job! No executable or dangerous file extensions detected57,371 lines of code in 114 files:
Language | Files | Blank lines | Comment lines | Lines of code |
---|---|---|---|---|
PHP | 36 | 2,253 | 2,821 | 20,413 |
SVG | 24 | 0 | 1 | 20,144 |
CSS | 22 | 369 | 306 | 7,997 |
JavaScript | 26 | 627 | 373 | 7,446 |
JSON | 4 | 5 | 0 | 773 |
PO File | 1 | 257 | 305 | 596 |
Markdown | 1 | 0 | 0 | 2 |
PHP code 50% from 2 tests
This plugin's cyclomatic complexity and code structure detailed below
Please fix the following
- Method cyclomatic complexity has to be reduced to less than 100 (currently 167)
Cyclomatic complexity | |
---|---|
Average complexity per logical line of code | 0.44 |
Average class complexity | 87.12 |
▷ Minimum class complexity | 1.00 |
▷ Maximum class complexity | 457.00 |
Average method complexity | 5.17 |
▷ Minimum method complexity | 1.00 |
▷ Maximum method complexity | 167.00 |
Code structure | ||
---|---|---|
Namespaces | 0 | |
Interfaces | 0 | |
Traits | 0 | |
Classes | 34 | |
▷ Abstract classes | 0 | 0.00% |
▷ Concrete classes | 34 | 100.00% |
▷ Final classes | 0 | 0.00% |
Methods | 703 | |
▷ Static methods | 23 | 3.27% |
▷ Public methods | 594 | 84.50% |
▷ Protected methods | 30 | 4.27% |
▷ Private methods | 79 | 11.24% |
Functions | 18 | |
▷ Named functions | 18 | 100.00% |
▷ Anonymous functions | 0 | 0.00% |
Constants | 8 | |
▷ Global constants | 8 | 100.00% |
▷ Class constants | 0 | 0.00% |
▷ Public constants | 0 | 0.00% |
Plugin size 50% from 2 tests
Image compression 50% from 2 tests
PNG files should be compressed to save space and minimize bandwidth usage
66 PNG files occupy 0.79MB with 0.22MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant | |||
---|---|---|---|
File | Size - original | Size - compressed | Savings |
public/img/si5.png | 61.39KB | 24.82KB | ▼ 59.57% |
admin/img/edit-icon.png | 0.26KB | 0.20KB | ▼ 21.13% |
public/img/ic_launcher2.old.png | 0.53KB | 0.63KB | 0.00% |
public/img/substract.png | 0.18KB | 0.11KB | ▼ 40.33% |
public/img/last.png | 0.35KB | 0.28KB | ▼ 21.27% |