72% automatic-youtube-video-posts

Code Review | Automatic Youtube Video Posts Plugin

WordPress plugin Automatic Youtube Video Posts Plugin scored72%from 54 tests.

About plugin

  • Plugin page: automatic-youtube...
  • Plugin version: 5.2.2
  • PHP version: 7.4.16
  • WordPress compatibility: 2.8-5.7.2
  • WordPress version: 6.3.1
  • First release: Sep 16, 2009
  • Latest release: May 28, 2021
  • Number of updates: 99
  • Update frequency: every 43.2 days
  • Top authors: mpraetzel (100%)

Code review

54 tests

User reviews

75 reviews

Install metrics

1,000+ active /276,617 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Installer ran successfully

Server metrics [RAM: ▲0.38MB] [CPU: ▲1.02ms] Passed 4 tests

Analyzing server-side resources used by Automatic Youtube Video Posts Plugin
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.79 ▲0.3337.00 ▼2.25
Dashboard /wp-admin3.75 ▲0.4448.45 ▼1.36
Posts /wp-admin/edit.php3.80 ▲0.4450.64 ▲8.54
Add New Post /wp-admin/post-new.php6.27 ▲0.3893.35 ▼0.87
Media Library /wp-admin/upload.php3.60 ▲0.3741.40 ▲8.83
Import Videos /wp-admin/admin.php?page=ayvpp-import-videos3.5733.45
Video Posts /wp-admin/admin.php?page=ayvpp-video-posts3.6233.09
Channels/Playlists /wp-admin/admin.php?page=ayvpp-channels3.6337.92
Settings /wp-admin/admin.php?page=ayvpp-settings3.5934.04
Duplicate Post Cleanup /wp-admin/admin.php?page=ayvpp-dups3.5730.55
Reset /wp-admin/admin.php?page=ayvpp-reset3.5832.25
Trouble Shooting /wp-admin/admin.php?page=ayvpp-trouble3.5833.47

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

How much does this plugin use your filesystem and database?
There were no storage issued detected upon installing this plugin
Filesystem: 82 new files
Database: no new tables, 7 new options
New WordPress options
widget_recent-comments
db_upgraded
ayvpp_settings
widget_theysaidso_widget
theysaidso_admin_options
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

An overview of browser requirements for Automatic Youtube Video Posts Plugin
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,849 ▲10313.20 ▼1.181.68 ▼0.1739.82 ▼4.93
Dashboard /wp-admin2,255 ▲674.87 ▼0.99111.11 ▲4.8554.71 ▲11.81
Posts /wp-admin/edit.php2,146 ▲542.02 ▼0.0340.24 ▼4.4949.13 ▲12.91
Add New Post /wp-admin/post-new.php1,573 ▲5023.19 ▼0.04604.13 ▼32.2535.06 ▼19.34
Media Library /wp-admin/upload.php1,434 ▲464.14 ▼0.0995.72 ▼3.5039.68 ▼1.38
Import Videos /wp-admin/admin.php?page=ayvpp-import-videos8122.0627.2843.04
Video Posts /wp-admin/admin.php?page=ayvpp-video-posts9952.0622.4042.43
Channels/Playlists /wp-admin/admin.php?page=ayvpp-channels1,3162.2427.3939.09
Settings /wp-admin/admin.php?page=ayvpp-settings3,0942.3439.8053.73
Duplicate Post Cleanup /wp-admin/admin.php?page=ayvpp-dups8282.0625.0334.07
Reset /wp-admin/admin.php?page=ayvpp-reset8962.1824.6539.00
Trouble Shooting /wp-admin/admin.php?page=ayvpp-trouble8892.0624.6639.63

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
The following items require your attention
  • The uninstall procedure has failed, leaving 7 options in the database
    • widget_recent-posts
    • ayvpp_settings
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-comments
    • db_upgraded
    • theysaidso_admin_options

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Smoke test failed, please fix the following
  • 6 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=ayvpp-channels
    • > Notice in wp-content/plugins/automatic-youtube-video-posts/admin/view/channel_add_free.php+60
    Trying to get property 'taxonomy' of non-object
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=ayvpp-channels
    • > Notice in wp-content/plugins/automatic-youtube-video-posts/admin/view/channel_add_free.php+60
    Trying to get property 'term_id' of non-object
  • 3 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=ayvpp-channels
    • > Notice in wp-content/plugins/automatic-youtube-video-posts/admin/view/channel_add_free.php+60
    Trying to get property 'name' of non-object

SRP 0% 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 items
  • 30× GET requests to PHP files return non-empty strings (only 10 are shown):
    • > /wp-content/plugins/automatic-youtube-video-posts/admin/class/reset.php
    • > /wp-content/plugins/automatic-youtube-video-posts/common/class/internal.php
    • > /wp-content/plugins/automatic-youtube-video-posts/vendor/ternstyle/wordpress/src/class/menu.php
    • > /wp-content/plugins/automatic-youtube-video-posts/common/init.php
    • > /wp-content/plugins/automatic-youtube-video-posts/admin/class/menu.php
    • > /wp-content/plugins/automatic-youtube-video-posts/admin/class/settings.php
    • > /wp-content/plugins/automatic-youtube-video-posts/admin/class/import.php
    • > /wp-content/plugins/automatic-youtube-video-posts/admin/view/settings-import.php
    • > /wp-content/plugins/automatic-youtube-video-posts/vendor/ternstyle/wordpress/src/class/option.php
    • > /wp-content/plugins/automatic-youtube-video-posts/admin/class/list.php
  • 16× GET requests to PHP files trigger server-side errors or Error 500 responses (only 10 are shown):
    • > PHP Notice
      Trying to access array offset on value of type null in wp-content/plugins/automatic-youtube-video-posts/admin/view/meta.php on line 7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/automatic-youtube-video-posts/admin/view/meta.php:9
    • > PHP Notice
      Undefined variable: meta in wp-content/plugins/automatic-youtube-video-posts/admin/view/meta.php on line 4
    • > PHP Notice
      Undefined variable: meta in wp-content/plugins/automatic-youtube-video-posts/admin/view/meta.php on line 7
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/automatic-youtube-video-posts/admin/view/reset.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/automatic-youtube-video-posts/admin/view/channels_free.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/automatic-youtube-video-posts/admin/view/channel_add.php:3
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/automatic-youtube-video-posts/admin/view/list.php:5
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/automatic-youtube-video-posts/admin/view/trouble.php:4
    • > PHP Fatal error
      Uncaught Error: Call to undefined function _e() in wp-content/plugins/automatic-youtube-video-posts/admin/view/import_free.php:3

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
10 plugin tags: youtube, youtube channel, videos, embed youtube videos, youtube videos...

automatic-youtube-video-posts/init.php 92% from 13 tests

Analyzing the main PHP file in "Automatic Youtube Video Posts Plugin" version 5.2.2
The following require your attention:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("automatic-youtube-video-posts.php" instead of "init.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are not allowed as they can serve as attack vectors
No dangerous file extensions were detected5,101 lines of code in 75 files:
LanguageFilesBlank linesComment linesLines of code
PHP549301,1294,469
LESS9241366
JavaScript757186251
CSS432310
JSON1005

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.41
Average class complexity19.72
▷ Minimum class complexity1.00
▷ Maximum class complexity114.00
Average method complexity2.95
▷ Minimum method complexity1.00
▷ Maximum method complexity38.00
Code structure
Namespaces5
Interfaces0
Traits0
Classes29
▷ Abstract classes00.00%
▷ Concrete classes29100.00%
▷ Final classes00.00%
Methods279
▷ Static methods196.81%
▷ Public methods18867.38%
▷ Protected methods00.00%
▷ Private methods9132.62%
Functions10
▷ Named functions330.00%
▷ Anonymous functions770.00%
Constants10
▷ Global constants10100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
PNG images were not found in this plugin