90% add-to-cart-button-labels-for-woocommerce

Code Review | Customize Add to Cart Button Text for WooCommerce

WordPress plugin Customize Add to Cart Button Text for WooCommerce scored90%from 54 tests.

About plugin

  • Plugin page: add-to-cart-butto...
  • Plugin version: 2.0.8
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-6.4
  • WordPress version: 6.3.1
  • First release: Feb 10, 2017
  • Latest release: Nov 23, 2023
  • Number of updates: 27
  • Update frequency: every 91.7 days
  • Top authors: algoritmika (74.07%)wpcodefactory (29.63%)

Code review

54 tests

User reviews

6 reviews

Install metrics

900+ active /13,100 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

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

Server metrics [RAM: ▲0.02MB] [CPU: ▼2.23ms] Passed 4 tests

This is a short check of server-side resources used by Customize Add to Cart Button Text for WooCommerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0233.69 ▼5.79
Dashboard /wp-admin3.33 ▲0.0246.22 ▼1.61
Posts /wp-admin/edit.php3.38 ▲0.0249.92 ▲1.59
Add New Post /wp-admin/post-new.php5.91 ▲0.0295.16 ▼0.35
Media Library /wp-admin/upload.php3.25 ▲0.0233.61 ▼1.17

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Customize Add to Cart Button Text for WooCommerce
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,815 ▲5314.21 ▼0.141.92 ▲0.1437.09 ▼8.53
Dashboard /wp-admin2,195 ▲155.63 ▲0.0191.81 ▼5.7039.63 ▼2.66
Posts /wp-admin/edit.php2,100 ▼01.94 ▼0.0439.27 ▼2.7135.63 ▲3.23
Add New Post /wp-admin/post-new.php1,526 ▼023.10 ▲0.24616.11 ▼25.3250.50 ▼5.90
Media Library /wp-admin/upload.php1,397 ▼34.23 ▲0.0797.91 ▲1.5043.09 ▲1.97

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options

Smoke tests Passed 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)
Everything seems fine, however this is by no means an exhaustive test

SRP Passed 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
Everything seems fine, however this is by no means an exhaustive test

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
No browser issues were found

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
3 plugin tags: woocommerce, add to cart, woo commerce

add-to-cart-button-labels-for-woocommerce/add-to-cart-button-labels-for-woocommerce.php Passed 13 tests

This is the main PHP file of "Customize Add to Cart Button Text for WooCommerce" version 2.0.8, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
66 characters long description:
Customize "Add to cart" button labels in WooCommerce. Beautifully.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
Success! There were no dangerous files found in this plugin1,201 lines of code in 15 files:
LanguageFilesBlank linesComment linesLines of code
PHP151906311,201

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.56
Average class complexity9.93
▷ Minimum class complexity2.00
▷ Maximum class complexity24.00
Average method complexity2.79
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes14
▷ Abstract classes00.00%
▷ Concrete classes14100.00%
▷ Final classes17.14%
Methods70
▷ Static methods11.43%
▷ Public methods70100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.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
PNG images were not found in this plugin