84% cartpull

Code Review | WooCommerce Abandoned Cart Recovery - HookMax

WordPress plugin WooCommerce Abandoned Cart Recovery - HookMax scored84%from 54 tests.

About plugin

  • Plugin page: cartpull
  • Plugin version: 1.0.2
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.8-5.6
  • WordPress version: 6.3.1
  • First release: Jul 17, 2019
  • Latest release: Feb 27, 2021
  • Number of updates: 14
  • Update frequency: every 42.3 days
  • Top authors: wpdebuglog (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /678 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

Server metrics [RAM: ▼0.63MB] [CPU: ▼17.23ms] Passed 4 tests

Analyzing server-side resources used by WooCommerce Abandoned Cart Recovery - HookMax
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0539.83 ▼0.58
Dashboard /wp-admin3.39 ▲0.0545.69 ▼7.41
Posts /wp-admin/edit.php3.50 ▲0.1150.23 ▼5.47
Add New Post /wp-admin/post-new.php3.27 ▼2.6637.64 ▼55.46
Media Library /wp-admin/upload.php3.31 ▲0.0438.69 ▲1.90

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

How much does this plugin use your filesystem and database?
This plugin was installed successfully
Filesystem: 7 new files
Database: no new tables, 7 new options
New WordPress options
cart-pull-key
can_compress_scripts
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
db_upgraded
theysaidso_admin_options

Browser metrics Passed 4 tests

An overview of browser requirements for WooCommerce Abandoned Cart Recovery - HookMax
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,830 ▲6914.24 ▲0.042.23 ▲0.4545.34 ▲3.02
Dashboard /wp-admin2,205 ▲285.55 ▼0.1185.53 ▼5.0938.94 ▼5.88
Posts /wp-admin/edit.php2,116 ▲162.01 ▲0.0539.48 ▼0.4836.02 ▼3.48
Add New Post /wp-admin/post-new.php1,544 ▲1823.16 ▲0.09689.37 ▲44.2665.76 ▲10.26
Media Library /wp-admin/upload.php1,416 ▲164.09 ▼0.11113.43 ▲10.3948.74 ▲2.15

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
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts
    • cart-pull-key
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget

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
Even though everything seems fine, this is not an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please take a closer look at the following
  • 2× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/cartpull/cart-pull.php:15
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/cartpull/admin/cart-pull-page.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
2 plugin tags: cart, woocommerce

cartpull/cart-pull.php 85% from 13 tests

Analyzing the main PHP file in "WooCommerce Abandoned Cart Recovery - HookMax" version 1.0.2
The following require your attention:
  • Main file name: The principal plugin file should be the same as the plugin slug ("cartpull.php" instead of "cart-pull.php")
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6

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
Everything looks great! No dangerous files found in this plugin215 lines of code in 6 files:
LanguageFilesBlank linesComment linesLines of code
PHP55217201
CSS11014

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.17
Average class complexity3.67
▷ Minimum class complexity3.00
▷ Maximum class complexity4.00
Average method complexity1.53
▷ Minimum method complexity1.00
▷ Maximum method complexity3.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods16
▷ Static methods425.00%
▷ Public methods1381.25%
▷ Protected methods00.00%
▷ Private methods318.75%
Functions3
▷ Named functions266.67%
▷ Anonymous functions133.33%
Constants1
▷ Global constants1100.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 are no PNG files in this plugin