89% woocommerce-embed-videos-to-product-image-gallery

Code Review | Embed Videos For Product Image Gallery Using WooCommerce

WordPress plugin Embed Videos For Product Image Gallery Using WooCommerce scored89%from 54 tests.

About plugin

  • Plugin page: woocommerce-embed...
  • Plugin version: 3.2
  • PHP compatiblity: 5.3+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0.1-6.3
  • WordPress version: 6.3.1
  • First release: Jun 1, 2015
  • Latest release: Aug 14, 2023
  • Number of updates: 123
  • Update frequency: every 24.4 days
  • Top authors: zealopensource (100%)

Code review

54 tests

User reviews

20 reviews

Install metrics

700+ active /49,507 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Installer ran successfully

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

This is a short check of server-side resources used by Embed Videos For Product Image Gallery Using WooCommerce
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0043.04 ▼7.77
Dashboard /wp-admin3.35 ▲0.0047.33 ▼2.94
Posts /wp-admin/edit.php3.40 ▲0.0047.79 ▼4.78
Add New Post /wp-admin/post-new.php5.93 ▲0.0094.20 ▼4.40
Media Library /wp-admin/upload.php3.27 ▲0.0036.34 ▼2.88

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Embed Videos For Product Image Gallery Using WooCommerce
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.72 ▲0.371.67 ▲0.0641.64 ▲1.55
Dashboard /wp-admin2,195 ▲185.60 ▼0.0593.34 ▲5.7740.51 ▼6.06
Posts /wp-admin/edit.php2,100 ▼01.94 ▼0.0938.70 ▲0.1035.32 ▼5.36
Add New Post /wp-admin/post-new.php1,526 ▼223.31 ▼0.11638.67 ▼58.3050.65 ▼2.27
Media Library /wp-admin/upload.php1,400 ▲34.18 ▲0.0696.64 ▼11.3142.85 ▼4.52

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_theysaidso_widget
    • widget_recent-posts
    • db_upgraded
    • can_compress_scripts

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for 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 applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
No output text or server-side errors detected on direct access of PHP files

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 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
10 plugin tags: video gallery, vimeo videos, videos woocommerce, iframe, woocommerce...

woocommerce-embed-videos-to-product-image-gallery/embed-videos-for-product-image-gallery-using-woocommerce.php 77% from 13 tests

Analyzing the main PHP file in "Embed Videos For Product Image Gallery Using WooCommerce" version 3.2
Please take the time to fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("woocommerce-embed-videos-to-product-image-gallery.php" instead of "embed-videos-for-product-image-gallery-using-woocommerce.php")
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug
  • Domain Path: The domain path folder was not found ("/languages")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Success! There were no dangerous files found in this plugin576 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP34381306
JavaScript14436173
CSS15097

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.39
Average class complexity0.00
▷ Minimum class complexity0.00
▷ Maximum class complexity0.00
Average method complexity0.00
▷ Minimum method complexity0.00
▷ Maximum method complexity0.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes0
▷ Abstract classes00.00%
▷ Concrete classes00.00%
▷ Final classes00.00%
Methods0
▷ Static methods00.00%
▷ Public methods00.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions13
▷ Named functions13100.00%
▷ Anonymous functions00.00%
Constants8
▷ Global constants8100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/images/play.png4.06KB1.49KB▼ 63.25%