84% video-expander

Code Review | Video Expander

WordPress plugin Video Expander scored84%from 54 tests.

About plugin

  • Plugin page: video-expander
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.6-4.3.1
  • WordPress version: 6.3.1
  • First release: Jan 2, 2016
  • Latest release: Jan 2, 2016
  • Number of updates: 3
  • Update frequency: every 1.0 days
  • Top authors: bcupham (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /989 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

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

A check of server-side resources used by Video Expander
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0040.02 ▼7.41
Dashboard /wp-admin3.31 ▼0.0344.47 ▼20.73
Posts /wp-admin/edit.php3.36 ▲0.0147.71 ▼2.01
Add New Post /wp-admin/post-new.php5.89 ▲0.0177.73 ▼20.19
Media Library /wp-admin/upload.php3.23 ▲0.0135.59 ▲1.44

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

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

Browser metrics Passed 4 tests

An overview of browser requirements for Video Expander
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.26 ▼1.131.84 ▼0.0743.43 ▼0.64
Dashboard /wp-admin2,203 ▲155.80 ▲0.9095.16 ▼21.0739.29 ▼3.58
Posts /wp-admin/edit.php2,089 ▼02.04 ▲0.0437.88 ▼0.2536.48 ▲5.59
Add New Post /wp-admin/post-new.php1,536 ▲323.22 ▲0.28654.92 ▲15.8052.36 ▲5.14
Media Library /wp-admin/upload.php1,388 ▲34.20 ▼0.10120.49 ▲22.2153.40 ▲9.26

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
  • Zombie WordPress options detected upon uninstall: 6 options
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_theysaidso_widget

Smoke tests 75% from 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)
Even though no errors were found, this is by no means an exhaustive test

SRP 50% from 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
Please fix the following
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/video-expander/video-expander.php:42

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 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
These attributes need your attention:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (Example of a group of video-expander shortcodes ready to be displayed!), #2 (Two column video-expander gallery), #3 (Two column video-expander gallery with expanded video)
You can look at the official readme.txt

video-expander/video-expander.php Passed 13 tests

The entry point to "Video Expander" version 1.0 is a PHP file that has certain tags in its header comment area
103 characters long description:
Creates shortcode to display video iframes in columns, where each video expands to play on mouse click.

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
Everything looks great! No dangerous files found in this plugin207 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
CSS17074
PHP1292172
JavaScript1181358
Markdown1103

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.17
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%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size 50% from 2 tests

Image compression 50% from 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
3 PNG files occupy 0.72MB with 0.30MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/screenshot-1.png170.55KB54.83KB▼ 67.85%
assets/screenshot-3.png560.85KB225.58KB▼ 59.78%
assets/play-button.png2.12KB2.19KB0.00%