10% recover-abandoned-cart-for-woocommerce

Code Review | Recover Abandoned Cart for WooCommerce

WordPress plugin Recover Abandoned Cart for WooCommerce scored10%from 54 tests.

About plugin

  • Plugin page: recover-abandoned...
  • Plugin version: 1.27.1
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-4.9
  • WordPress version: 6.3.1
  • First release: Apr 13, 2018
  • Latest release: Apr 27, 2018
  • Number of updates: 4
  • Update frequency: every 3.8 days
  • Top authors: azexo (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /643 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Please fix the following installer errors
  • Install procedure had errors
    • > Error in wp-content/plugins/recover-abandoned-cart-for-woocommerce/azh_woo_recover_abandoned _cart.php+849
    Uncaught Error: Call to undefined function azr_run() in wp-content/plugins/recover-abandoned-cart-for-woocommerce/azh_woo_recover_abandoned _cart.php:849
    Stack trace:
    #0 wp-content/plugins/recover-abandoned-cart-for-woocommerce/azh_woo_recover_abandoned _cart.php(62): azm_woo_rac_create_defualt_campaign()
    #1 wp-includes/class-wp-hook.php(310): azm_woo_rac_activate()
    #2 wp-includes/class-wp-hook.php(334): WP_Hook->apply_filters()
    #3 wp-includes/plugin.php(517): WP_Hook->do_action()
    #4 wp-admin/includes/plugin.php(693): do_action()

Server metrics [RAM: ▲0.00MB] [CPU: ▼7.33ms] Passed 4 tests

This is a short check of server-side resources used by Recover Abandoned Cart for WooCommerce
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0043.15 ▼3.95
Dashboard /wp-admin3.31 ▲0.0048.30 ▼3.76
Posts /wp-admin/edit.php3.36 ▲0.0047.90 ▼2.82
Add New Post /wp-admin/post-new.php5.89 ▲0.0078.86 ▼18.77
Media Library /wp-admin/upload.php3.23 ▲0.0038.20 ▼0.01

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

Analyzing filesystem and database footprints of this plugin
No storage issues were detected
Filesystem: 3 new files
Database: 2 new tables, 7 new options
New tables
wp_azm_woo_abandoned_carts_rules
wp_azm_woo_abandoned_carts
New WordPress options
theysaidso_admin_options
widget_recent-posts
widget_recent-comments
can_compress_scripts
db_upgraded
azm_woo_rac_defualt_campaign
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by Recover Abandoned Cart for WooCommerce
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.71 ▲0.161.82 ▲0.2241.99 ▼0.32
Dashboard /wp-admin2,192 ▲155.62 ▼0.0590.76 ▼5.4141.32 ▼7.08
Posts /wp-admin/edit.php2,100 ▼02.02 ▲0.0239.83 ▲2.9636.50 ▲2.85
Add New Post /wp-admin/post-new.php1,528 ▲223.18 ▲0.27674.97 ▼32.3967.16 ▲15.60
Media Library /wp-admin/upload.php1,394 ▼64.20 ▼0.0299.68 ▼12.0048.81 ▲2.29

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 2 tables in the database
    • wp_azm_woo_abandoned_carts_rules
    • wp_azm_woo_abandoned_carts
  • This plugin does not fully uninstall, leaving 7 options in the database
    • widget_recent-posts
    • db_upgraded
    • azm_woo_rac_defualt_campaign
    • widget_theysaidso_widget
    • widget_recent-comments
    • can_compress_scripts
    • theysaidso_admin_options

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP Passed 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
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that require attention:
  • Tags: There are too many tags (13 tag instead of maximum 10)
The official readme.txt is a good inspiration

recover-abandoned-cart-for-woocommerce/azh_woo_recover_abandoned _cart.php 85% from 13 tests

The entry point to "Recover Abandoned Cart for WooCommerce" version 1.27.1 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Main file name: Name the main plugin file the same as the plugin slug ("recover-abandoned-cart-for-woocommerce.php" instead of "azh_woo_recover_abandoned _cart.php")
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Everything looks great! No dangerous files found in this plugin782 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP19443782

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity65.00
▷ Minimum class complexity65.00
▷ Maximum class complexity65.00
Average method complexity6.33
▷ Minimum method complexity1.00
▷ Maximum method complexity32.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods12
▷ Static methods00.00%
▷ Public methods12100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions29
▷ Named functions2896.55%
▷ Anonymous functions13.45%
Constants0
▷ Global constants00.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
There were not PNG files found in your plugin