84% super-fast-side-cart-for-woocommerce

Code Review | Super Fast Side Cart for WooCommerce

WordPress plugin Super Fast Side Cart for WooCommerce scored84%from 54 tests.

About plugin

  • Plugin page: super-fast-side-c...
  • Plugin version: 1.0.6
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.8-6.0.2
  • WordPress version: 6.3.1
  • First release: Feb 9, 2021
  • Latest release: Oct 10, 2022
  • Number of updates: 16
  • Update frequency: every 38.1 days
  • Top authors: storepro (81.25%)jafarsadiqutc (25%)

Code review

54 tests

User reviews

1 review

Install metrics

30+ active /1,312 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
The plugin installed successfully, without throwing any errors or notices

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

An overview of server-side resources used by Super Fast Side Cart for WooCommerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.46 ▲0.0044.78 ▲0.47
Dashboard /wp-admin3.31 ▼0.0447.31 ▼21.15
Posts /wp-admin/edit.php3.36 ▲0.0049.12 ▲0.46
Add New Post /wp-admin/post-new.php5.89 ▲0.0087.25 ▲2.04
Media Library /wp-admin/upload.php3.23 ▲0.0039.34 ▼4.25

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 14 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget

Browser metrics Passed 4 tests

A check of browser resources used by Super Fast Side Cart for WooCommerce
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲4514.25 ▼0.161.93 ▲0.0642.22 ▼3.03
Dashboard /wp-admin2,198 ▲185.58 ▼0.0685.69 ▼11.6638.49 ▼5.99
Posts /wp-admin/edit.php2,103 ▲32.01 ▲0.0339.62 ▲1.2936.25 ▼4.94
Add New Post /wp-admin/post-new.php1,526 ▼023.41 ▲0.25662.39 ▼33.8352.87 ▼10.07
Media Library /wp-admin/upload.php1,397 ▼04.14 ▼0.15103.85 ▼20.3046.55 ▼6.98

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
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
Almost there! Just fix the following items
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/super-fast-side-cart-for-woocommerce/sp_side_cart.php

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)
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
10 plugin tags: ajax, popup cart, woocommerce, floating cart, cart...

super-fast-side-cart-for-woocommerce/sp_side_cart.php 92% from 13 tests

The principal PHP file in "Super Fast Side Cart for WooCommerce" v. 1.0.6 is loaded by WordPress automatically on each request
Please make the necessary changes and fix the following:
  • Main file name: Name the main plugin file the same as the plugin slug ("super-fast-side-cart-for-woocommerce.php" instead of "sp_side_cart.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
There were no executable files found in this plugin990 lines of code in 10 files:
LanguageFilesBlank linesComment linesLines of code
PHP321555724
JavaScript54011255
CSS20011

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.36
Average class complexity34.67
▷ Minimum class complexity7.00
▷ Maximum class complexity49.00
Average method complexity3.30
▷ Minimum method complexity1.00
▷ Maximum method complexity13.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods31
▷ Static methods26.45%
▷ Public methods31100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants4
▷ Global constants4100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
2 PNG files occupy 0.03MB with 0.01MB in potential savings
Potential savings
Compression of 2 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/images/float-scart-icon.png31.67KB11.09KB▼ 64.97%
assets/images/close-scart.png0.52KB0.37KB▼ 28.52%