72% advanced-video-player-with-analytics

Code Review | Advanced Video Player with Analytics

WordPress plugin Advanced Video Player with Analytics scored72%from 54 tests.

About plugin

  • Plugin page: advanced-video-pl...
  • Plugin version: 1...
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.2-5.4
  • WordPress version: 6.3.1
  • First release: May 16, 2020
  • Latest release: May 16, 2020
  • Number of updates: 5
  • Update frequency: every 0.2 days
  • Top authors: sony7596 (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /896 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
Installer ran successfully

Server metrics [RAM: ▲0.08MB] [CPU: ▼6.65ms] Passed 4 tests

Server-side resources used by Advanced Video Player with Analytics
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0841.48 ▼1.10
Dashboard /wp-admin3.40 ▲0.0650.47 ▼16.53
Posts /wp-admin/edit.php3.52 ▲0.1756.05 ▲4.35
Add New Post /wp-admin/post-new.php5.97 ▲0.0893.08 ▼7.20
Media Library /wp-admin/upload.php3.31 ▲0.0838.38 ▼1.76
Advanced Video Player with Analytics /wp-admin/options-general.php?page=avpa3.3135.41
Video detail /wp-admin/admin.php?page=video-detail-page3.3133.60

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

Filesystem and database footprint
No storage issues were detected
Filesystem: 115 new files
Database: no new tables, 6 new options
New WordPress options
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-comments
widget_recent-posts
can_compress_scripts
db_upgraded

Browser metrics Passed 4 tests

This is an overview of browser requirements for Advanced Video Player with Analytics
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,971 ▲22514.48 ▼0.051.94 ▼0.3738.73 ▼8.10
Dashboard /wp-admin2,355 ▲1756.14 ▲0.47110.40 ▲26.4540.94 ▲2.83
Posts /wp-admin/edit.php2,288 ▲1853.30 ▲1.3450.38 ▲11.3133.97 ▼2.00
Add New Post /wp-admin/post-new.php1,543 ▲1223.22 ▲0.18640.47 ▼18.8036.77 ▼16.66
Media Library /wp-admin/upload.php1,428 ▲254.16 ▲0.0584.28 ▼22.1043.84 ▼5.55
Advanced Video Player with Analytics /wp-admin/options-general.php?page=avpa9733.0337.8821.92
Video detail /wp-admin/admin.php?page=video-detail-page6891.689.7117.58

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-comments
    • widget_theysaidso_widget
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts
    • db_upgraded

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
These server-side errors were triggered
    • > GET request to /wp-admin/admin.php?page=video-detail-page
    • > Notice in wp-content/plugins/advanced-video-player-with-analytics/templates/video-detail.php+2
    Undefined index: id

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
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/advanced-video-player-with-analytics/templates/shortcode-generator.php
  • 5× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Query' not found in wp-content/plugins/advanced-video-player-with-analytics/templates/tracking-data.php:5
    • > PHP Notice
      Undefined index: id in wp-content/plugins/advanced-video-player-with-analytics/templates/video-detail.php on line 2
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_post() in wp-content/plugins/advanced-video-player-with-analytics/templates/video-detail.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function __() in wp-content/plugins/advanced-video-player-with-analytics/templates/settings.php:1
    • > PHP Fatal error
      Uncaught Error: Call to undefined function plugin_dir_path() in wp-content/plugins/advanced-video-player-with-analytics/admin.php:6

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

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
These attributes need to be fixed:
  • Tags: There are too many tags (11 tag instead of maximum 10)
The official readme.txt might help

advanced-video-player-with-analytics/advanced-video-player-with-analytics.php 85% from 13 tests

The main PHP script in "Advanced Video Player with Analytics" version 1... is automatically included on every request by WordPress
You should first fix the following items:
  • Version: The version number should be digits and periods (ex. "1.0.3" instead of "1...")
  • Text Domain: The text domain must be the same as the plugin slug, although optional since WordPress version 4.6

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is a short overview of programming languages used in this plugin, detecting executable files
No dangerous file extensions were detected135,797 lines of code in 106 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript5539,99889,646131,311
JSON37102,251
CSS6229111,522
PHP713870599
SVG100114

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.26
Average class complexity2.00
▷ Minimum class complexity2.00
▷ Maximum class complexity2.00
Average method complexity1.50
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes1
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
Methods2
▷ Static methods00.00%
▷ Public methods2100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions16
▷ Named functions16100.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
No PNG files were detected