90% storefront-product-sharing

Code Review | Storefront Product Sharing

WordPress plugin Storefront Product Sharing scored 90% from 54 tests.

About plugin

  • Plugin page: storefront-produc...
  • Plugin version: 1.0.6
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-5.2
  • WordPress version: 6.3.1
  • First release: Apr 23, 2015
  • Latest release: Aug 27, 2020
  • Number of updates: 14
  • Update frequency: every 139.5 days
  • Top authors: woothemes (50%)jameskoster (35.71%)tiagonoronha (21.43%)wpmuguru (14.29%)

Code review

54 tests

User reviews

14 reviews

Install metrics

10,000+ active / 270,299 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 gracefully, with no errors

Server metrics [RAM: ▲0.03MB] [CPU: ▼4.58ms] Passed 4 tests

This is a short check of server-side resources used by Storefront Product Sharing
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0334.08 ▼4.49
Dashboard /wp-admin3.34 ▲0.0347.89 ▼5.32
Posts /wp-admin/edit.php3.39 ▲0.0342.64 ▼5.72
Add New Post /wp-admin/post-new.php5.92 ▲0.0390.67 ▼2.77
Media Library /wp-admin/upload.php3.26 ▲0.0347.44 ▲12.88

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

How much does this plugin use your filesystem and database?
No storage issues were detected
Filesystem: 6 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
db_upgraded
widget_recent-comments
widget_recent-posts
widget_theysaidso_widget
storefront-product-sharing-version
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Storefront Product Sharing
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,816 ▲7013.36 ▼1.321.63 ▼0.2840.68 ▲0.97
Dashboard /wp-admin2,219 ▲315.79 ▼0.0996.59 ▼24.9841.59 ▼12.67
Posts /wp-admin/edit.php2,104 ▲152.00 ▼0.0141.73 ▲0.3740.88 ▲3.73
Add New Post /wp-admin/post-new.php1,535 ▲623.27 ▲4.79650.48 ▼61.5455.97 ▼1.26
Media Library /wp-admin/upload.php1,404 ▲164.24 ▲0.06113.98 ▲5.7347.21 ▲0.27

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • The uninstall procedure has failed, leaving 7 options in the database
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • storefront-product-sharing-version

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)
Good news, no errors were detected

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
No output text or server-side errors detected on direct access of PHP files

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
6 plugin tags: woocommerce, storefront, social, ecommerce, sharing...

storefront-product-sharing/storefront-product-sharing.php Passed 13 tests

The principal PHP file in "Storefront Product Sharing" v. 1.0.6 is loaded by WordPress automatically on each request
101 characters long description:
Add attractive social sharing icons for Facebook, Twitter, Pinterest and Email to your product pages.

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
There were no executable files found in this plugin255 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
Sass1212105
PHP23013091
CSS16059

PHP code Passed 2 tests

This is a very shot review of cyclomatic complexity and code structure
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.14
Average class complexity7.00
▷ Minimum class complexity7.00
▷ Maximum class complexity7.00
Average method complexity1.50
▷ Minimum method complexity1.00
▷ Maximum method complexity4.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes1100.00%
Methods12
▷ Static methods18.33%
▷ Public methods1191.67%
▷ Protected methods00.00%
▷ Private methods18.33%
Functions1
▷ Named functions1100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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