72% woo-video-gallery

Code Review | Woo Video Gallery

WordPress plugin Woo Video Gallery scored72%from 54 tests.

About plugin

  • Plugin page: woo-video-gallery
  • Plugin version: 1.0.5
  • PHP version: 7.4.16
  • WordPress compatibility: 4.0-4.4.2
  • WordPress version: 6.3.1
  • First release: Aug 3, 2016
  • Latest release: Aug 11, 2016
  • Number of updates: 9
  • Update frequency: every 1.4 days
  • Top authors: jalilfulan (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

10+ active /6,237 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Install script ran successfully

Server metrics [RAM: ▼0.01MB] [CPU: ▼4.66ms] Passed 4 tests

An overview of server-side resources used by Woo Video Gallery
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0039.22 ▼0.21
Dashboard /wp-admin3.31 ▼0.0447.70 ▼9.98
Posts /wp-admin/edit.php3.36 ▲0.0045.06 ▲0.38
Add New Post /wp-admin/post-new.php5.89 ▲0.0088.53 ▼8.83
Media Library /wp-admin/upload.php3.23 ▲0.0034.13 ▲1.72
Woo Video Gallery /wp-admin/options-general.php?page=video-gallery-settings3.0121.77

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 37 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_recent-posts
can_compress_scripts
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Woo Video Gallery
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,789 ▲2814.72 ▲0.351.86 ▲0.3543.54 ▲5.24
Dashboard /wp-admin2,198 ▲185.61 ▲0.0096.62 ▲9.6340.76 ▼0.48
Posts /wp-admin/edit.php2,100 ▼01.99 ▲0.0333.45 ▼1.4935.98 ▲2.31
Add New Post /wp-admin/post-new.php1,526 ▼023.12 ▼0.41635.16 ▼29.6450.73 ▲2.87
Media Library /wp-admin/upload.php1,397 ▼34.22 ▼0.02103.56 ▼10.6745.33 ▼2.52
Woo Video Gallery /wp-admin/options-general.php?page=video-gallery-settings280.420.083.96

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 were found after uninstall: 6 options
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded

Smoke tests 25% from 4 tests

Server-side errors Passed 1 test

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

SRP 0% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 1× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/woo-video-gallery/WooVideoGallery.php
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function WooVideoGallery\\get_post_meta() in wp-content/plugins/woo-video-gallery/WooFrontend.php:59

User-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Please fix the following browser errors
    • > GET request to /wp-admin/options-general.php?page=video-gallery-settings
    • > Network (severe)
    wp-admin/options-general.php?page=video-gallery-settings - Failed to load resource: the server responded with a status of 403 (Forbidden)

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
Attributes that require attention:
  • Tags: Too many tags (11 tag instead of maximum 10); only the first 5 tags are used in your directory listing
You can take inspiration from this readme.txt

woo-video-gallery/WooVideoGallery.php 92% from 13 tests

The principal PHP file in "Woo Video Gallery" v. 1.0.5 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Main file name: The principal plugin file should be the same as the plugin slug ("woo-video-gallery.php" instead of "WooVideoGallery.php")

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
Everything looks great! No dangerous files found in this plugin1,799 lines of code in 16 files:
LanguageFilesBlank linesComment linesLines of code
PHP5150149753
JavaScript55731528
CSS33626394
JSON10063
HTML13250
SVG10011

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.29
Average class complexity13.75
▷ Minimum class complexity2.00
▷ Maximum class complexity29.00
Average method complexity3.32
▷ Minimum method complexity1.00
▷ Maximum method complexity16.00
Code structure
Namespaces1
Interfaces0
Traits0
Classes4
▷ Abstract classes00.00%
▷ Concrete classes4100.00%
▷ Final classes00.00%
Methods22
▷ Static methods22100.00%
▷ Public methods2090.91%
▷ Protected methods00.00%
▷ Private methods29.09%
Functions1
▷ Named functions00.00%
▷ Anonymous functions1100.00%
Constants1
▷ Global constants00.00%
▷ Class constants1100.00%
▷ Public constants1100.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
16 PNG files occupy 0.90MB with 0.29MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/star.png0.80KB1.16KB0.00%
images/facebook.png2.76KB1.86KB▼ 32.53%
images/gplus.png3.21KB1.80KB▼ 43.88%
images/playvideo.png0.54KB0.45KB▼ 16.94%
images/Screenshot from 2016-06-22 18_31_19.png211.97KB73.28KB▼ 65.43%