90% wpc-share-cart

Code Review | WPC Share Cart for WooCommerce

WordPress plugin WPC Share Cart for WooCommerce scored90%from 54 tests.

About plugin

  • Plugin page: wpc-share-cart
  • Plugin version: 1.2.7
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-6.3
  • WordPress version: 6.3.1
  • First release: Mar 31, 2021
  • Latest release: Oct 28, 2023
  • Number of updates: 29
  • Update frequency: every 32.5 days
  • Top authors: wpclever (100%)

Code review

54 tests

User reviews

6 reviews

Install metrics

1,000+ active /11,117 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

Server metrics [RAM: ▲0.24MB] [CPU: ▲0.38ms] Passed 4 tests

This is a short check of server-side resources used by WPC Share Cart for WooCommerce
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.70 ▲0.2439.53 ▲5.00
Dashboard /wp-admin3.54 ▲0.2446.77 ▼4.07
Posts /wp-admin/edit.php3.65 ▲0.3049.84 ▲3.18
Add New Post /wp-admin/post-new.php6.14 ▲0.2595.07 ▲1.58
Media Library /wp-admin/upload.php3.46 ▲0.2337.00 ▲0.82
Essential Kit /wp-admin/admin.php?page=wpclever-kit3.4330.95
About /wp-admin/admin.php?page=wpclever3.4329.23

Server storage [IO: ▲0.47MB] [DB: ▲0.02MB] Passed 3 tests

Filesystem and database footprint
There were no storage issued detected upon installing this plugin
Filesystem: 19 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_recent-comments
can_compress_scripts
widget_recent-posts
db_upgraded
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for WPC Share Cart for WooCommerce
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,866 ▲10514.32 ▼0.241.77 ▲0.2243.33 ▲5.22
Dashboard /wp-admin2,257 ▲805.65 ▼0.0083.57 ▼3.7686.16 ▲46.73
Posts /wp-admin/edit.php2,178 ▲782.02 ▲0.0039.99 ▲3.7937.87 ▲5.24
Add New Post /wp-admin/post-new.php1,609 ▲8124.73 ▲1.57687.02 ▼4.5773.96 ▲19.30
Media Library /wp-admin/upload.php1,471 ▲714.20 ▼0.01100.35 ▲1.8883.85 ▲37.71
Essential Kit /wp-admin/admin.php?page=wpclever-kit5,7412.1532.5153.11
About /wp-admin/admin.php?page=wpclever1,3992.1430.5542.98

Uninstaller [IO: ▲0.00MB] [DB: ▲0.02MB] 75% from 4 tests

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
It is recommended to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded

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
The smoke test was a success, however most plugin functionality was not tested

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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
5 plugin tags: woocommerce, share, woo, wpc, cart

wpc-share-cart/wpc-share-cart.php Passed 13 tests

The main file in "WPC Share Cart for WooCommerce" v. 1.2.7 serves as a complement to information provided in readme.txt and as the entry point to the plugin
90 characters long description:
WPC Share Cart is a simple but powerful tool that can help your customer share their cart.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
There were no executable files found in this plugin2,301 lines of code in 14 files:
LanguageFilesBlank linesComment linesLines of code
PHP5151411,118
CSS41006543
SVG200521
JavaScript32512119

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.37
Average class complexity35.00
▷ Minimum class complexity1.00
▷ Maximum class complexity92.00
Average method complexity4.40
▷ Minimum method complexity1.00
▷ Maximum method complexity30.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods40
▷ Static methods410.00%
▷ Public methods40100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions266.67%
▷ Anonymous functions133.33%
Constants8
▷ Global constants8100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
There were not PNG files found in your plugin