89% videojs-hls-player

Code Review | Video.js HLS Player

WordPress plugin Video.js HLS Player scored89%from 54 tests.

About plugin

  • Plugin page: videojs-hls-player
  • Plugin version: 1.0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.2-4.7
  • WordPress version: 6.3.1
  • First release: Nov 22, 2016
  • Latest release: Nov 25, 2016
  • Number of updates: 11
  • Update frequency: every 1.1 days
  • Top authors: star2dev (100%)

Code review

54 tests

User reviews

4 reviews

Install metrics

900+ active /0 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

Server metrics [RAM: ▲0.04MB] [CPU: ▲1.29ms] Passed 4 tests

A check of server-side resources used by Video.js HLS Player
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.52 ▲0.0638.20 ▼0.72
Dashboard /wp-admin3.35 ▲0.0544.93 ▼4.25
Posts /wp-admin/edit.php3.40 ▲0.0446.46 ▲3.14
Add New Post /wp-admin/post-new.php5.93 ▲0.0499.50 ▲7.67
Media Library /wp-admin/upload.php3.28 ▲0.0436.98 ▲7.00
Video.js HLS Player /wp-admin/options-general.php?page=videojs-hls-player-settings3.2430.58

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Video.js HLS Player
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,965 ▲23015.14 ▲0.7745.07 ▲43.1244.01 ▼7.07
Dashboard /wp-admin2,213 ▲284.84 ▼0.25106.67 ▼14.1139.09 ▼3.22
Posts /wp-admin/edit.php2,093 ▲42.00 ▼0.0136.10 ▲1.4231.93 ▼4.76
Add New Post /wp-admin/post-new.php1,536 ▲823.29 ▲0.21661.32 ▲3.5161.84 ▲1.45
Media Library /wp-admin/upload.php1,389 ▲44.19 ▼0.0195.47 ▼4.4241.72 ▲0.73
Video.js HLS Player /wp-admin/options-general.php?page=videojs-hls-player-settings7362.1824.0924.47

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
    • can_compress_scripts
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded
    • theysaidso_admin_options
    • widget_theysaidso_widget

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 everything seems fine, this is not 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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 93% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is an important file in your plugin as it is parsed by WordPress.org to prepare the public listing of your plugin
Attributes that require attention:
  • Tags: You are using too many tags: 20 tag instead of maximum 10
The official readme.txt is a good inspiration

videojs-hls-player/videojs-hls-player.php 92% from 13 tests

The entry point to "Video.js HLS Player" version 1.0.2 is a PHP file that has certain tags in its header comment area
The following require your attention:
  • Description: Please keep the plugin description shorter than 140 characters (currently 197 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Success! There were no dangerous files found in this plugin359 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP14522209
JavaScript322775
CSS217064
SVG10011

PHP code Passed 2 tests

This is a short overview 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 complexity5.00
▷ Minimum class complexity5.00
▷ Maximum class complexity5.00
Average method complexity1.57
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods7
▷ Static methods00.00%
▷ Public methods7100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions3
▷ Named functions3100.00%
▷ Anonymous functions00.00%
Constants1
▷ Global constants1100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Using a strong compression for your PNG files is a great way to speed-up your plugin
There are no PNG files in this plugin