73% wootoolkit

Code Review | WooToolkit- A Scalable WooCommerce Addon!

WordPress plugin WooToolkit- A Scalable WooCommerce Addon! scored73%from 54 tests.

About plugin

  • Plugin page: wootoolkit
  • Plugin version: 1.0.2
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.3.1
  • WordPress version: 6.3.1
  • First release: Apr 26, 2017
  • Latest release: Sep 4, 2023
  • Number of updates: 23
  • Update frequency: every 101.0 days
  • Top authors: dipakbbsr (47.83%)Magnigenie (43.48%)kshirod patel (13.04%)sagarseth9 (8.7%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,205 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.01MB] [CPU: ▼4.15ms] Passed 4 tests

An overview of server-side resources used by WooToolkit- A Scalable WooCommerce Addon!
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0133.64 ▼10.19
Dashboard /wp-admin3.31 ▲0.0143.78 ▼16.70
Posts /wp-admin/edit.php3.36 ▲0.0148.35 ▲0.35
Add New Post /wp-admin/post-new.php5.89 ▲0.01102.57 ▲15.35
Media Library /wp-admin/upload.php3.23 ▲0.0142.88 ▲9.96
Installed Kits /wp-admin/admin.php?page=woo-toolkit3.0025.15
Settings /wp-admin/admin.php?page=woo-toolkit-settings3.0029.42

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

How much does this plugin use your filesystem and database?
This plugin installed successfully
Filesystem: 45 new files
Database: no new tables, 15 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
widget_recent-posts
wootoolkit_catalog
wootoolkit_sorting_options
wootoolkit_products_per_page
theysaidso_admin_options
can_compress_scripts
wootoolkit_accordion
wootoolkit_mailchimp
...

Browser metrics Passed 4 tests

Checking browser requirements for WooToolkit- A Scalable WooCommerce Addon!
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.22 ▼1.461.80 ▲0.0036.99 ▼6.67
Dashboard /wp-admin2,209 ▲215.91 ▲0.02107.54 ▼3.4742.56 ▼2.25
Posts /wp-admin/edit.php2,089 ▼02.04 ▲0.0839.07 ▲3.5835.75 ▼1.21
Add New Post /wp-admin/post-new.php1,533 ▲1423.35 ▲0.30598.48 ▼31.0549.12 ▼7.89
Media Library /wp-admin/upload.php1,391 ▼04.17 ▼0.0198.56 ▼3.5345.75 ▲2.31
Installed Kits /wp-admin/admin.php?page=woo-toolkit280.440.083.94
Settings /wp-admin/admin.php?page=woo-toolkit-settings280.440.073.92

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
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 15 options
    • wootoolkit_sorting_options
    • wootoolkit_mailchimp
    • wootoolkit_continue_shopping
    • wootoolkit_accordion
    • can_compress_scripts
    • wootoolkit_products_per_page
    • widget_recent-posts
    • theysaidso_admin_options
    • wootoolkit_catalog
    • wootoolkit_empty_cart
    • ...

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 0% 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
Please take a closer look at the following
  • 2× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/wootoolkit/kits/wootoolkit-empty-cart/includes/admin/empty-cart-admin.php
    • > /wp-content/plugins/wootoolkit/kits/wootoolkit-product-sorting-options/includes/class-admin-settings.php
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wootoolkit/includes/wootoolkit.class.php:18
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/wootoolkit/kits/wootoolkit-catalog/wootoolkit-catalog.php:32
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/wootoolkit/includes/wootoolkit.settings.class.php:43

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
These are user-side errors you should fix
    • > GET request to /wp-admin/admin.php?page=woo-toolkit
    • > Network (severe)
    wp-admin/admin.php?page=woo-toolkit - Failed to load resource: the server responded with a status of 403 (Forbidden)
    • > GET request to /wp-admin/admin.php?page=woo-toolkit-settings
    • > Network (severe)
    wp-admin/admin.php?page=woo-toolkit-settings - Failed to load resource: the server responded with a status of 403 (Forbidden)

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 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
These attributes need to be fixed:
  • Tags: Please delete some tags, you are using 12 tag instead of maximum 10
You can take inspiration from this readme.txt

wootoolkit/wootoolkit.php Passed 13 tests

"WooToolkit- A Scalable WooCommerce Addon!" version 1.0.2's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
49 characters long description:
One stop solution for all your WooCommerce needs.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected3,182 lines of code in 38 files:
LanguageFilesBlank linesComment linesLines of code
PHP299911,6042,605
CSS450342
JavaScript55968235

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.38
Average class complexity13.65
▷ Minimum class complexity1.00
▷ Maximum class complexity69.00
Average method complexity2.91
▷ Minimum method complexity1.00
▷ Maximum method complexity22.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes26
▷ Abstract classes00.00%
▷ Concrete classes26100.00%
▷ Final classes00.00%
Methods173
▷ Static methods116.36%
▷ Public methods16494.80%
▷ Protected methods21.16%
▷ Private methods74.05%
Functions12
▷ Named functions1191.67%
▷ Anonymous functions18.33%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.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
1 PNG file occupies 0.02MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/images/woo_toolkit_icon.png17.58KB0.44KB▼ 97.52%