57% easy-video-publisher

Code Review | Easy Video Publisher

WordPress plugin Easy Video Publisher scored57%from 54 tests.

About plugin

  • Plugin page: easy-video-publisher
  • Plugin version: 4.0.13
  • PHP compatiblity: 7.2.5+
  • PHP version: 7.4.16
  • WordPress compatibility: 3.4-5.7
  • WordPress version: 6.3.1
  • First release: Oct 13, 2020
  • Latest release: Jun 12, 2022
  • Number of updates: 19
  • Update frequency: every 32.0 days
  • Top authors: icelayer (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /2,003 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.33MB] [CPU: ▼3.42ms] Passed 4 tests

An overview of server-side resources used by Easy Video Publisher
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.74 ▲0.2842.78 ▼2.20
Dashboard /wp-admin3.66 ▲0.3550.14 ▼0.90
Posts /wp-admin/edit.php3.71 ▲0.3553.40 ▲3.14
Add New Post /wp-admin/post-new.php6.24 ▲0.3590.24 ▼13.41
Media Library /wp-admin/upload.php3.58 ▲0.3538.14 ▲2.83
Add Channel /wp-admin/admin.php?page=evp-add-channel3.7537.09
YouTube /wp-admin/admin.php?page=evp-youtube3.6741.77
Channel Import /wp-admin/admin.php?page=evp-channel-import3.7637.23
API Setup /wp-admin/admin.php?page=evp-api-setup3.6135.88
Settings /wp-admin/admin.php?page=evp-video-publisher3.7033.14

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

A short overview of filesystem and database impact
This plugin was installed successfully
Filesystem: 301 new files
Database: 3 new tables, 10 new options
New tables
wp_evp_videos
wp_queue_failures
wp_queue_jobs
New WordPress options
evp_channels
evp_youtube_api
widget_theysaidso_widget
widget_recent-posts
widget_recent-comments
evp_version
evp_restricted_categories
db_upgraded
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

Easy Video Publisher: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,841 ▲9513.26 ▼1.141.82 ▲0.0840.86 ▼1.08
Dashboard /wp-admin2,247 ▲565.85 ▼0.0399.20 ▼9.3340.40 ▼0.84
Posts /wp-admin/edit.php2,130 ▲412.05 ▲0.0638.93 ▼3.1635.98 ▼0.20
Add New Post /wp-admin/post-new.php1,561 ▲4723.29 ▲5.71676.48 ▼9.3656.91 ▼2.73
Media Library /wp-admin/upload.php1,426 ▲384.25 ▼0.0099.52 ▼6.1244.56 ▼2.21
Add Channel /wp-admin/admin.php?page=evp-add-channel9562.2030.5059.58
YouTube /wp-admin/admin.php?page=evp-youtube1,4835.58109.6861.97
Channel Import /wp-admin/admin.php?page=evp-channel-import1,2711.9025.1439.16
API Setup /wp-admin/admin.php?page=evp-api-setup9522.0624.0641.30
Settings /wp-admin/admin.php?page=evp-video-publisher9702.2224.7239.86

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • This plugin does not fully uninstall, leaving 2 tables in the database
    • wp_queue_failures
    • wp_queue_jobs
  • Zombie WordPress options detected upon uninstall: 6 options
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options
    • widget_recent-posts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
The smoke test was a success, however most plugin functionality was not tested

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 take a closer look at the following
  • 1× PHP files output non-empty strings when accessed directly via GET requests:
    • > /wp-content/plugins/easy-video-publisher/vendor/symfony/translation/Resources/bin/translation-status.php
  • 83× PHP files trigger server-side errors or warnings when accessed directly (only 10 are shown):
    • > PHP Fatal error
      Uncaught Error: Interface 'Symfony\\Component\\Translation\\Dumper\\DumperInterface' not found in wp-content/plugins/easy-video-publisher/vendor/symfony/translation/Dumper/FileDumper.php:26
    • > PHP Fatal error
      Uncaught Error: Class 'PHPUnit\\Framework\\TestCase' not found in wp-content/plugins/easy-video-publisher/vendor/a5hleyrich/wp-queue/tests/TestWorker.php:8
    • > PHP Fatal error
      Uncaught Error: Class 'VideoPublisherlite\\Database\\WPDb' not found in wp-content/plugins/easy-video-publisher/src/Database/VideosTable.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'Symfony\\Component\\Translation\\Loader\\FileLoader' not found in wp-content/plugins/easy-video-publisher/vendor/symfony/translation/Loader/PhpFileLoader.php:19
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Queue\\Job' not found in wp-content/plugins/easy-video-publisher/src/Post/ChannelImport.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'Symfony\\Component\\Translation\\Dumper\\FileDumper' not found in wp-content/plugins/easy-video-publisher/vendor/symfony/translation/Dumper/CsvFileDumper.php:21
    • > PHP Fatal error
      Uncaught Error: Interface 'Symfony\\Component\\Translation\\TranslatorInterface' not found in wp-content/plugins/easy-video-publisher/vendor/symfony/translation/Translator.php:32
    • > PHP Fatal error
      Uncaught Error: Class 'Symfony\\Component\\HttpKernel\\DataCollector\\DataCollector' not found in wp-content/plugins/easy-video-publisher/vendor/symfony/translation/DataCollector/TranslationDataCollector.php:26
    • > PHP Fatal error
      Uncaught Error: Class 'Symfony\\Component\\Translation\\Extractor\\AbstractFileExtractor' not found in wp-content/plugins/easy-video-publisher/vendor/symfony/translation/Extractor/PhpExtractor.php:22
    • > PHP Fatal error
      Uncaught Error: Class 'Symfony\\Component\\Translation\\Dumper\\FileDumper' not found in wp-content/plugins/easy-video-publisher/vendor/symfony/translation/Dumper/XliffFileDumper.php:22

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 86% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
6 plugin tags: youtube, youtube channel, post, thumbnail, youtube embed...

easy-video-publisher/video-publisher.php 69% from 13 tests

The principal PHP file in "Easy Video Publisher" v. 4.0.13 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Domain Path: The domain path should be prefixed with a forward slash character ("/languages")
  • Requires at least: The required version number did not match the one declared in readme.txt ("4.0" instead of "3.4")
  • Domain Path: Note that the domain path follows the same naming rules as the domain name, using only dashes and lowercase characters ("languages")
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("easy-video-publisher.php" instead of "video-publisher.php")

Code Analysis 3% from 3 tests

File types 0% from 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
Please fix the following items
  • Even if your plugin relies on executable files (for example a companion app), never distribute executable files with your plugin
    • .bat - Batch File in Windows
      • wp-content/plugins/easy-video-publisher/vendor/nesbot/carbon/bin/upgrade-carbon.bat
22,775 lines of code in 284 files:
LanguageFilesBlank linesComment linesLines of code
PHP2453,7319,50118,001
XSD392482,803
JSON900917
Markdown122130711
CSS3172223
HTML50042
YAML49039
XML21035
DOS Batch1004

PHP code 50% from 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
Please tend to the following items
  • Cyclomatic complexity of methods should be reduced to less than 100 (currently 159)
Cyclomatic complexity
Average complexity per logical line of code0.44
Average class complexity14.07
▷ Minimum class complexity1.00
▷ Maximum class complexity263.00
Average method complexity2.74
▷ Minimum method complexity1.00
▷ Maximum method complexity159.00
Code structure
Namespaces37
Interfaces20
Traits3
Classes128
▷ Abstract classes75.47%
▷ Concrete classes12194.53%
▷ Final classes54.13%
Methods1,178
▷ Static methods25421.56%
▷ Public methods1,00084.89%
▷ Protected methods958.06%
▷ Private methods837.05%
Functions82
▷ Named functions5364.63%
▷ Anonymous functions2935.37%
Constants86
▷ Global constants33.49%
▷ Class constants8396.51%
▷ Public constants83100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
There were not PNG files found in your plugin