72% woo-customization-add-to-cart-checkout

Code Review | woo customization add to cart heckout

WordPress plugin woo customization add to cart heckout scored72%from 54 tests.

About plugin

  • Plugin page: woo-customization...
  • Plugin version: 1.0
  • PHP compatiblity: 5.2+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.7-5.0.3
  • WordPress version: 6.3.1
  • First release: May 9, 2019
  • Latest release: May 9, 2019
  • Number of updates: 5
  • Update frequency: N/A
  • Top authors: maharishaq (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /4,594 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲1.25MB] [CPU: ▲3.98ms] Passed 4 tests

This is a short check of server-side resources used by woo customization add to cart heckout
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /4.72 ▲1.2546.20 ▲3.55
Dashboard /wp-admin4.61 ▲1.3063.36 ▲9.86
Posts /wp-admin/edit.php4.66 ▲1.3068.44 ▲19.37
Add New Post /wp-admin/post-new.php7.13 ▲1.2491.88 ▼11.03
Media Library /wp-admin/upload.php4.44 ▲1.2151.28 ▲13.52

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

A short overview of filesystem and database impact
There were no storage issued detected upon installing this plugin
Filesystem: 459 new files
Database: no new tables, 6 new options
New WordPress options
can_compress_scripts
widget_recent-comments
widget_recent-posts
theysaidso_admin_options
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

An overview of browser requirements for woo customization add to cart heckout
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,990 ▲22918.89 ▲4.251.65 ▼0.2839.24 ▼6.95
Dashboard /wp-admin2,393 ▲2169.43 ▲3.76186.32 ▲82.3841.02 ▼4.21
Posts /wp-admin/edit.php2,329 ▲2326.66 ▲4.64116.87 ▲80.7334.19 ▼0.50
Add New Post /wp-admin/post-new.php1,576 ▲5026.25 ▲3.03767.70 ▲100.3237.13 ▼15.23
Media Library /wp-admin/upload.php1,466 ▲697.26 ▲3.03137.92 ▲19.6044.98 ▼4.14
WC Customization /wp-admin/crb_carbon_fields_container_wc_customization.php260.420.1215.27

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
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • widget_theysaidso_widget
    • db_upgraded

Smoke tests 25% 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 no errors were found, this is by no means an exhaustive test

SRP 0% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
The following issues need your attention
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/woo-customization-add-to-cart-checkout/inc/option_fields/vendor/htmlburger/carbon-fields/templates/Exception/incorrect-syntax.php
  • 205× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\Test\\TestCase' not found in wp-content/plugins/woo-customization-add-to-cart-checkout/inc/option_fields/vendor/composer/installers/tests/Composer/Installers/Test/PimcoreInstallerTest.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Container\\Condition\\Term_Condition' not found in wp-content/plugins/woo-customization-add-to-cart-checkout/inc/option_fields/vendor/htmlburger/carbon-fields/core/Container/Condition/Post_Term_Condition.php:30
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Container\\Container' not found in wp-content/plugins/woo-customization-add-to-cart-checkout/inc/option_fields/vendor/htmlburger/carbon-fields/core/Container/Theme_Options_Container.php:11
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/woo-customization-add-to-cart-checkout/inc/option_fields/vendor/composer/installers/src/Composer/Installers/PiwikInstaller.php:9
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\Test\\TestCase' not found in wp-content/plugins/woo-customization-add-to-cart-checkout/inc/option_fields/vendor/composer/installers/tests/Composer/Installers/Test/YawikInstallerTest.php:14
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/woo-customization-add-to-cart-checkout/inc/option_fields/vendor/composer/installers/src/Composer/Installers/WordPressInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\Test\\TestCase' not found in wp-content/plugins/woo-customization-add-to-cart-checkout/inc/option_fields/vendor/composer/installers/tests/Composer/Installers/Test/InstallerTest.php:11
    • > PHP Fatal error
      Uncaught Error: Using $this when not in object context in wp-content/plugins/woo-customization-add-to-cart-checkout/inc/option_fields/vendor/htmlburger/carbon-fields/templates/Container/theme_options.php:2
    • > PHP Fatal error
      Uncaught Error: Class 'Composer\\Installers\\BaseInstaller' not found in wp-content/plugins/woo-customization-add-to-cart-checkout/inc/option_fields/vendor/composer/installers/src/Composer/Installers/MicroweberInstaller.php:4
    • > PHP Fatal error
      Uncaught Error: Class 'Carbon_Fields\\Container\\Container' not found in wp-content/plugins/woo-customization-add-to-cart-checkout/inc/option_fields/vendor/htmlburger/carbon-fields/core/Container/Post_Meta_Container.php:14

User-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Please take a look at the following user-side issues
    • > GET request to /wp-admin/crb_carbon_fields_container_wc_customization.php
    • > Network (severe)
    wp-admin/crb_carbon_fields_container_wc_customization.php - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 90% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
5 plugin tags: woocommerce customiz, wp woo customization, woo customization, customiz cart text, change cart button text

woo-customization-add-to-cart-checkout/index.php 77% from 13 tests

This is the main PHP file of "woo customization add to cart heckout" version 1.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Description: Please don't use more than 140 characters for the plugin description (currently 176 characters long)
  • Requires at least: Required version does not match the one declared in readme.txt ("4.9" instead of "3.7")
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("woo-customization-add-to-cart-checkout.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin74,357 lines of code in 436 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript14015,91728,38559,703
PHP2402,5626,39710,673
PO File121,1321,6232,507
JSON800580
CSS28289125566
Markdown5610279
YAML27026
XML12023

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity5.08
▷ Minimum class complexity1.00
▷ Maximum class complexity50.00
Average method complexity1.99
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces25
Interfaces5
Traits0
Classes215
▷ Abstract classes136.05%
▷ Concrete classes20293.95%
▷ Final classes10.50%
Methods923
▷ Static methods818.78%
▷ Public methods73479.52%
▷ Protected methods18219.72%
▷ Private methods70.76%
Functions95
▷ Named functions2324.21%
▷ Anonymous functions7275.79%
Constants32
▷ Global constants721.88%
▷ Class constants2578.12%
▷ Public constants25100.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 files were detected