99% advanced-embed-for-youtube

Code Review | Advanced Embed For YouTube

WordPress plugin Advanced Embed For YouTube scored 99% from 54 tests.

About plugin

  • Plugin page: advanced-embed-fo...
  • Plugin version: 1.0.0
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-5.7
  • WordPress version: 5.8.1
  • First release: Apr 20, 2021
  • Latest release: Apr 20, 2021
  • Number of updates: 4
  • Update frequency: every 2.8 days
  • Top authors: kashberg (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 178 total downloads


Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.00MB] [CPU: ▼143.64ms] Passed 4 tests

Analyzing server-side resources used by Advanced Embed For YouTube
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /2.85 ▲0.0124.56 ▲3.73
Dashboard /wp-admin3.07 ▲0.0030.75 ▼6.19
Posts /wp-admin/edit.php3.12 ▲0.0131.02 ▲1.34
Add New Post /wp-admin/post-new.php5.42 ▼0.0270.80 ▼570.18
Media Library /wp-admin/upload.php3.01 ▲0.0122.22 ▲0.49

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 4 new files
Database: no new tables, no new options

Browser metrics Passed 4 tests

This is an overview of browser requirements for Advanced Embed For YouTube
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,666 ▲6515.99 ▲0.184.92 ▼0.9978.76 ▲1.12
Dashboard /wp-admin2,929 ▲336.11 ▼0.03115.21 ▼18.57164.17 ▼12.35
Posts /wp-admin/edit.php2,737 ▼63.22 ▼0.0163.85 ▼1.67133.91 ▼1.24
Add New Post /wp-admin/post-new.php3,817 ▲11119.72 ▲0.70447.88 ▲5.00190.66 ▲28.92
Media Library /wp-admin/upload.php1,746 ▼65.51 ▼0.00149.94 ▲12.70197.92 ▲7.86

Uninstaller [IO: ▲0.00MB] [DB: ▲0.00MB] Passed 4 tests

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
This plugin's uninstaller ran successfully

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Good news, no errors were detected

SRP Passed 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
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected


Plugin configuration 83% from 29 tests

readme.txt 94% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
Attributes that need to be fixed:
  • Contributors: Plugin contributors not specified
The official readme.txt is a good inspiration

advanced-embed-for-youtube/wp-embed-youtube.php 69% from 13 tests

"Advanced Embed For YouTube" version 1.0.0's primary PHP file adds more information about the plugin and serves as the entry point for WordPress
The following require your attention:
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("advanced-embed-for-youtube.php" instead of "wp-embed-youtube.php")
  • Domain Path: The domain path points to an invalid folder, "/languages" does not exist
  • Description: Please keep the plugin description shorter than 140 characters (currently 197 characters long)
  • Text Domain: You no longer need to specify the text domain since WordPress 4.6; it must be the same as the plugin slug

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
Good job! No executable or dangerous file extensions detected39 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code

PHP code Passed 2 tests

Analyzing logical lines of code, cyclomatic complexity, and other code metrics
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.17
Average class complexity2.00
▷ Minimum class complexity2.00
▷ Maximum class complexity2.00
Average method complexity1.25
▷ Minimum method complexity1.00
▷ Maximum method complexity2.00
Code structure
▷ Abstract classes00.00%
▷ Concrete classes1100.00%
▷ Final classes00.00%
▷ Static methods125.00%
▷ Public methods375.00%
▷ Protected methods00.00%
▷ Private methods125.00%
▷ Named functions1100.00%
▷ Anonymous functions00.00%
▷ Global constants2100.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
There were not PNG files found in your plugin