84% collector-checkout-for-woocommerce

Code Review | Walley Checkout for WooCommerce

WordPress plugin Walley Checkout for WooCommerce scored84%from 54 tests.

About plugin

  • Plugin page: collector-checkou...
  • Plugin version: 4.0.9
  • PHP compatiblity: 7.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 6.0.0-6.4.1
  • WordPress version: 6.3.1
  • First release: Sep 18, 2017
  • Latest release: Nov 21, 2023
  • Number of updates: 152
  • Update frequency: every 14.9 days
  • Top authors: collectorbank (100%)

Code review

54 tests

User reviews

1 review

Install metrics

60+ active /8,414 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Install script ran successfully

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

This is a short check of server-side resources used by Walley Checkout for WooCommerce
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0134.83 ▼5.28
Dashboard /wp-admin3.31 ▲0.0145.66 ▼4.33
Posts /wp-admin/edit.php3.36 ▲0.0149.29 ▼0.04
Add New Post /wp-admin/post-new.php5.89 ▲0.0193.48 ▲1.51
Media Library /wp-admin/upload.php3.23 ▲0.0135.06 ▲2.86

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 88 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_theysaidso_widget
db_upgraded
theysaidso_admin_options
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for Walley Checkout for WooCommerce
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,790 ▲314.04 ▼0.301.74 ▼0.2338.15 ▼8.55
Dashboard /wp-admin2,198 ▲245.61 ▼0.0894.20 ▼4.4842.64 ▼2.20
Posts /wp-admin/edit.php2,103 ▲32.02 ▲0.0140.35 ▼3.0937.19 ▲0.22
Add New Post /wp-admin/post-new.php1,526 ▼023.46 ▲0.23609.63 ▼74.2249.18 ▼3.35
Media Library /wp-admin/upload.php1,400 ▼34.21 ▲0.0197.74 ▼1.8140.80 ▼2.42

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
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Good news, no errors were detected

SRP 50% 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 fix the following items
  • 3× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Warning
      Invalid argument supplied for foreach() in wp-content/plugins/collector-checkout-for-woocommerce/templates/walley-checkout-meta-box.php on line 8
    • > PHP Notice
      Undefined variable: manage_orders in wp-content/plugins/collector-checkout-for-woocommerce/templates/walley-checkout-meta-box.php on line 14
    • > PHP Notice
      Undefined variable: keys_for_meta_box in wp-content/plugins/collector-checkout-for-woocommerce/templates/walley-checkout-meta-box.php on line 8

User-side errors Passed 1 test

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

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
6 plugin tags: checkout, e-commerce, collector, ecommerce, woocommerce...

collector-checkout-for-woocommerce/collector-checkout-for-woocommerce.php 85% from 13 tests

Analyzing the main PHP file in "Walley Checkout for WooCommerce" version 4.0.9
You should first fix the following items:
  • Requires at least: Required version does not match the one declared in readme.txt ("5.0" instead of "6.0.0")
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 143 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin7,911 lines of code in 82 files:
LanguageFilesBlank linesComment linesLines of code
PHP721,2623,3976,418
PO File3325352849
JavaScript34586455
CSS3166178
SVG10011

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity12.18
▷ Minimum class complexity1.00
▷ Maximum class complexity90.00
Average method complexity3.34
▷ Minimum method complexity1.00
▷ Maximum method complexity24.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes66
▷ Abstract classes46.06%
▷ Concrete classes6293.94%
▷ Final classes00.00%
Methods319
▷ Static methods7322.88%
▷ Public methods24777.43%
▷ Protected methods5617.55%
▷ Private methods165.02%
Functions32
▷ Named functions32100.00%
▷ Anonymous functions00.00%
Constants8
▷ Global constants8100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
1 PNG file occupies 0.01MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/images/collector_bank_logo_blackgrey.png6.98KB3.37KB▼ 51.69%