73% super-video-player

Code Review | Super Video Player

WordPress plugin Super Video Player scored 73% from 54 tests.

About plugin

  • Plugin page: super-video-player
  • Plugin version: 1.7.0
  • PHP compatiblity: 7.1+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3
  • WordPress version: 6.3.1
  • First release: Jan 23, 2019
  • Latest release: Sep 23, 2023
  • Number of updates: 110
  • Update frequency: every 15.5 days
  • Top authors: abuhayat (78.18%)shehabulislam (22.73%)

Code review

54 tests

User reviews

26 reviews

Install metrics

3,000+ active / 53,022 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲5.41MB] [CPU: ▲35.62ms] 75% from 4 tests

A check of server-side resources used by Super Video Player
The following require your attention
  • Extra RAM: The extra memory usage must be under 5MB (currently 5.41MB on /wp-admin/admin.php?page=freemius)
PageMemory (MB)CPU Time (ms)
Home /8.93 ▲5.4682.41 ▲35.33
Dashboard /wp-admin8.95 ▲5.6484.95 ▲34.28
Posts /wp-admin/edit.php8.95 ▲5.5983.17 ▲38.88
Add New Post /wp-admin/post-new.php10.85 ▲4.96129.06 ▲33.99
Media Library /wp-admin/upload.php8.95 ▲5.7280.13 ▲46.48
Freemius Debug [v.2.5.12] /wp-admin/admin.php?page=freemius8.9566.16

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 370 new files
Database: no new tables, 9 new options
New WordPress options
db_upgraded
theysaidso_admin_options
widget_recent-posts
widget_recent-comments
fs_active_plugins
fs_accounts
widget_theysaidso_widget
can_compress_scripts
fs_debug_mode

Browser metrics Passed 4 tests

An overview of browser requirements for Super Video Player
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,945 ▲19914.05 ▼0.5710.43 ▲8.7033.14 ▼10.26
Dashboard /wp-admin2,227 ▲395.82 ▼0.0899.45 ▼6.6786.79 ▲46.44
Posts /wp-admin/edit.php2,125 ▲361.98 ▼0.0538.71 ▲3.7639.09 ▲2.71
Add New Post /wp-admin/post-new.php1,523 ▼2122.28 ▲3.83694.61 ▲66.0359.83 ▲0.92
Media Library /wp-admin/upload.php1,424 ▲334.27 ▲0.0695.87 ▼5.8872.36 ▲28.27
Freemius Debug [v.2.5.12] /wp-admin/admin.php?page=freemius1,0991.6823.3833.55

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
It is recommended to fix the following
  • Uninstall procedure had uncaught errors
    • > Notice in wp-content/plugins/super-video-player/freemius/includes/class-freemius.php+8515
    Undefined property: stdClass::$plugins
  • The uninstall procedure has failed, leaving 9 options in the database
    • theysaidso_admin_options
    • widget_recent-posts
    • widget_recent-comments
    • can_compress_scripts
    • fs_debug_mode
    • widget_theysaidso_widget
    • db_upgraded
    • fs_active_plugins
    • fs_accounts

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)
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
Please fix the following
  • 10× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function SVP\\Model\\add_action() in wp-content/plugins/super-video-player/inc/Model/Menu.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/super-video-player/admin/inc/metabox-free-backup.php:136
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/super-video-player/admin/inc/help-usages.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/super-video-player/admin/inc/metabox-free.php:389
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/super-video-player/inc/shortcode-free.php:69
    • > PHP Fatal error
      Uncaught Error: Call to undefined function SVP\\Model\\add_action() in wp-content/plugins/super-video-player/inc/Model/EnqueueAssets.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/super-video-player/admin/blocks/init.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function HTML5Player\\PostType\\add_action() in wp-content/plugins/super-video-player/inc/PostType/SVPPlayer.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function HTML5Player\\PostType\\add_action() in wp-content/plugins/super-video-player/inc/PostType/SVPPlayer.php:8
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/super-video-player/inc/notice.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 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
5 plugin tags: video player, plyr, video gallery, mp4 player, media player

super-video-player/super-video-player.php 92% from 13 tests

The entry point to "Super Video Player" version 1.7.0 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
  • Text Domain: Since WordPress version 4.6 the text domain is optional; if specified, it must be the same as the plugin slug

Code Analysis 97% from 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
There were no executable files found in this plugin69,075 lines of code in 297 files:
LanguageFilesBlank linesComment linesLines of code
PHP21811,50518,80748,541
PO File213,0653,4456,249
Sass1595234,811
JavaScript141,2874204,632
CSS242904884,467
Markdown1680214
JSON100143
XML13016
SVG2002

PHP code 50% from 2 tests

An overview of cyclomatic complexity and code structure
It is recommended to fix the following
  • Class cyclomatic complexity has to be reduced to less than 1000 (currently 3,088)
Cyclomatic complexity
Average complexity per logical line of code0.63
Average class complexity53.55
▷ Minimum class complexity1.00
▷ Maximum class complexity3,088.00
Average method complexity4.93
▷ Minimum method complexity1.00
▷ Maximum method complexity94.00
Code structure
Namespaces3
Interfaces0
Traits0
Classes113
▷ Abstract classes43.54%
▷ Concrete classes10996.46%
▷ Final classes00.00%
Methods1,539
▷ Static methods24916.18%
▷ Public methods1,14774.53%
▷ Protected methods171.10%
▷ Private methods37524.37%
Functions136
▷ Named functions13599.26%
▷ Anonymous functions10.74%
Constants148
▷ Global constants10168.24%
▷ Class constants4731.76%
▷ Public constants47100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
4 PNG files occupy 0.02MB with 0.01MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
img/icon.png1.45KB0.78KB▼ 46.16%
admin/codestar-framework/assets/images/checkerboard.png2.29KB2.54KB0.00%
freemius/assets/img/theme-icon.png10.97KB5.78KB▼ 47.37%
freemius/assets/img/plugin-icon.png9.16KB5.26KB▼ 42.58%