89% sizeme-for-woocommerce

Code Review | SizeMe for WooCommerce

WordPress plugin SizeMe for WooCommerce scored89%from 54 tests.

About plugin

  • Plugin page: sizeme-for-woocom...
  • Plugin version: 2.3.3
  • PHP compatiblity: 5.2.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 2.5-6.3.1
  • WordPress version: 6.3.1
  • First release: May 24, 2019
  • Latest release: Sep 15, 2023
  • Number of updates: 15
  • Update frequency: every 105.7 days
  • Top authors: sizeme (100%)

Code review

54 tests

User reviews

1 review

Install metrics

80+ active /3,638 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

Server metrics [RAM: ▲0.00MB] [CPU: ▼2.26ms] Passed 4 tests

A check of server-side resources used by SizeMe for WooCommerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0044.51 ▲7.85
Dashboard /wp-admin3.31 ▲0.0047.95 ▼0.15
Posts /wp-admin/edit.php3.36 ▲0.0043.47 ▼0.58
Add New Post /wp-admin/post-new.php5.89 ▲0.0091.19 ▼12.96
Media Library /wp-admin/upload.php3.23 ▲0.0040.29 ▲4.65

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 7 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
widget_theysaidso_widget
can_compress_scripts
widget_recent-comments
db_upgraded
theysaidso_admin_options

Browser metrics Passed 4 tests

This is an overview of browser requirements for SizeMe for WooCommerce
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.27 ▼0.291.85 ▲0.0542.72 ▲5.84
Dashboard /wp-admin2,192 ▲145.57 ▼0.0382.37 ▼14.3440.35 ▼2.29
Posts /wp-admin/edit.php2,100 ▼01.96 ▼0.0134.69 ▼2.0933.94 ▲0.62
Add New Post /wp-admin/post-new.php1,526 ▼222.99 ▼0.09654.50 ▼35.6355.65 ▲0.25
Media Library /wp-admin/upload.php1,394 ▼34.23 ▲0.0598.76 ▼0.8341.43 ▼1.75

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
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 90% from 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
5 plugin tags: measurements, sizeguide, size guide, sizeme, size recommendations

sizeme-for-woocommerce/sizeme-for-woocommerce.php 77% from 13 tests

"SizeMe for WooCommerce" version 2.3.3's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
Please take the time 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
  • Description: If Twitter did it, so should we! Keep the description under 140 characters (currently 155 characters long)
  • Requires at least: Required version does not match the one declared in readme.txt ("3.8" instead of "2.5")

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
Good job! No executable or dangerous file extensions detected711 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP5173784711

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.35
Average class complexity32.00
▷ Minimum class complexity2.00
▷ Maximum class complexity62.00
Average method complexity2.59
▷ Minimum method complexity1.00
▷ Maximum method complexity14.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods39
▷ Static methods25.13%
▷ Public methods3076.92%
▷ Protected methods820.51%
▷ Private methods12.56%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants31
▷ Global constants00.00%
▷ Class constants31100.00%
▷ Public constants31100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There were not PNG files found in your plugin