10% youtube-new-generation

Code Review | YouTube New Generation

WordPress plugin YouTube New Generation scored10%from 54 tests.

About plugin

  • Plugin page: youtube-new-gener...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-4.2.2
  • WordPress version: 6.3.1
  • First release: Jun 19, 2015
  • Latest release: Jun 19, 2015
  • Number of updates: 3
  • Update frequency: every 0.3 days
  • Top authors: feijao (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /1,089 total downloads

Benchmarks

Plugin footprint 57% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Please fix the following installer errors
  • Install procedure had errors
    • > Notice in wp-content/plugins/youtube-new-generation/youtube-new-generation.php+53
    Undefined index: items

Server metrics [RAM: ▲0.03MB] [CPU: ▼2.83ms] Passed 4 tests

Server-side resources used by YouTube New Generation
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0439.20 ▼2.57
Dashboard /wp-admin3.33 ▲0.0348.51 ▼3.01
Posts /wp-admin/edit.php3.38 ▲0.0350.37 ▼3.06
Add New Post /wp-admin/post-new.php5.91 ▲0.0395.79 ▼2.66
Media Library /wp-admin/upload.php3.26 ▲0.0338.76 ▲3.21

Server storage [IO: ▲0.03MB] [DB: ▲0.00MB] 67% from 3 tests

How much does this plugin use your filesystem and database?
These are issues you should consider
  • Illegal file modification detected: 1 file (4.00KB) outside of "wp-content/plugins/youtube-new-generation/" and "wp-content/uploads/"
    • (new file) wp-content/mgd_mirror/mgd_maximinodotpy-gitdown-test-repository
Filesystem: 6 new files
Database: no new tables, 8 new options
New WordPress options
yt_nw_gen_videos
yt_nw_gen_settings
theysaidso_admin_options
can_compress_scripts
db_upgraded
widget_theysaidso_widget
widget_recent-comments
widget_recent-posts

Browser metrics Passed 4 tests

An overview of browser requirements for YouTube New Generation
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,833 ▲4714.74 ▲0.371.81 ▼0.3938.92 ▼3.84
Dashboard /wp-admin2,234 ▲315.85 ▼0.05104.87 ▼14.3643.47 ▼2.44
Posts /wp-admin/edit.php2,116 ▲372.00 ▼0.0539.89 ▲5.5837.83 ▲0.58
Add New Post /wp-admin/post-new.php1,539 ▲717.63 ▼5.39674.83 ▼0.5051.44 ▼1.13
Media Library /wp-admin/upload.php1,413 ▲134.27 ▲0.0297.64 ▼12.6749.49 ▲1.40

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • widget_recent-comments
    • widget_recent-posts
    • theysaidso_admin_options
    • db_upgraded
    • can_compress_scripts
    • 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)
Everything seems fine, however 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 items
  • 3× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/youtube-new-generation/youtube-new-generation.php:14
    • > PHP Fatal error
      Uncaught Error: Call to undefined function get_option() in wp-content/plugins/youtube-new-generation/admin.php:25
    • > PHP Notice
      Undefined index: google_key in wp-content/plugins/youtube-new-generation/admin.php on line 5

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
No browser errors were detected

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
3 plugin tags: youtube, list videos, youtube channel

youtube-new-generation/youtube-new-generation.php 92% from 13 tests

The primary PHP file in "YouTube New Generation" version 1.0 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Description: The description should be shorter than 140 characters (currently 235 characters long)

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
No dangerous file extensions were detected183 lines of code in 4 files:
LanguageFilesBlank linesComment linesLines of code
PHP26222141
CSS16040
Markdown1002

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.09
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%
Functions7
▷ Named functions7100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
No PNG images were found in this plugin