78% continue-shopping-anywhere-for-woocommerce

Code Review | Continue Shopping Anywhere for WooCommerce

WordPress plugin Continue Shopping Anywhere for WooCommerce scored78%from 54 tests.

About plugin

  • Plugin page: continue-shopping...
  • Plugin version: 1.3.0
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-6.0
  • WordPress version: 6.3.1
  • First release: Sep 18, 2019
  • Latest release: Sep 4, 2022
  • Number of updates: 7
  • Update frequency: every 154.4 days
  • Top authors: ivanchernyakov (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

1,000+ active /6,697 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.08MB] [CPU: ▼0.19ms] Passed 4 tests

A check of server-side resources used by Continue Shopping Anywhere for WooCommerce
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.55 ▲0.0841.57 ▲0.11
Dashboard /wp-admin3.38 ▲0.0852.67 ▲1.96
Posts /wp-admin/edit.php3.49 ▲0.1454.24 ▼1.35
Add New Post /wp-admin/post-new.php5.98 ▲0.10103.16 ▲4.31
Media Library /wp-admin/upload.php3.30 ▲0.0834.07 ▼1.50

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

Input-output and database impact of this plugin
This plugin installed successfully
Filesystem: 23 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
db_upgraded
theysaidso_admin_options
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

An overview of browser requirements for Continue Shopping Anywhere for WooCommerce
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,912 ▲16613.64 ▼0.748.55 ▲6.6242.82 ▼1.14
Dashboard /wp-admin2,210 ▲285.81 ▼0.08101.45 ▼6.2738.36 ▼1.42
Posts /wp-admin/edit.php2,093 ▲12.01 ▲0.0040.16 ▼2.9734.24 ▼0.56
Add New Post /wp-admin/post-new.php1,527 ▲718.78 ▼4.25630.69 ▲28.0553.48 ▼2.83
Media Library /wp-admin/upload.php1,386 ▼24.19 ▼0.1894.84 ▼3.9944.25 ▼3.16

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
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Even though everything seems fine, this is not 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
The following issues need your attention
  • 2× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/continue-shopping-anywhere-for-woocommerce/admin/partials/continue-shopping-anywhere-admin-display.php
    • > /wp-content/plugins/continue-shopping-anywhere-for-woocommerce/public/partials/continue-shopping-anywhere-public-display.php
  • 1× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'WC_Settings_Page' not found in wp-content/plugins/continue-shopping-anywhere-for-woocommerce/admin/partials/continue-shopping-anywhere-admin-display-settings.php:21

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
No browser issues were found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
5 plugin tags: continue shopping, ecommerce, woocommerce, notice, shopping

continue-shopping-anywhere-for-woocommerce/continue-shopping-anywhere.php 85% from 13 tests

The main PHP script in "Continue Shopping Anywhere for WooCommerce" version 1.3.0 is automatically included on every request by WordPress
It is important to fix the following:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("continue-shopping-anywhere-for-woocommerce.php" instead of "continue-shopping-anywhere.php")

Code Analysis Passed 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
No dangerous file extensions were detected562 lines of code in 17 files:
LanguageFilesBlank linesComment linesLines of code
PHP13173628556
JavaScript24546
CSS2080

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
Great job! No cyclomatic complexity issues were detected in this plugin
Cyclomatic complexity
Average complexity per logical line of code0.22
Average class complexity5.25
▷ Minimum class complexity1.00
▷ Maximum class complexity24.00
Average method complexity1.97
▷ Minimum method complexity1.00
▷ Maximum method complexity15.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes8
▷ Abstract classes00.00%
▷ Concrete classes8100.00%
▷ Final classes00.00%
Methods35
▷ Static methods25.71%
▷ Public methods3085.71%
▷ Protected methods00.00%
▷ Private methods514.29%
Functions4
▷ Named functions4100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
No PNG images were found in this plugin