90% video-block-with-ads

Code Review | Video Block with Ads

WordPress plugin Video Block with Ads scored90%from 54 tests.

About plugin

  • Plugin page: video-block-with-ads
  • Plugin version: 0.71
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 2.5-5.1
  • WordPress version: 6.3.1
  • First release: Feb 14, 2019
  • Latest release: Apr 25, 2019
  • Number of updates: 9
  • Update frequency: every 7.8 days
  • Top authors: federico_jacobi (100%)

Code review

54 tests

User reviews

1 review

Install metrics

40+ active /2,172 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
Installer ran successfully

Server metrics [RAM: ▲0.07MB] [CPU: ▼4.76ms] Passed 4 tests

Analyzing server-side resources used by Video Block with Ads
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.54 ▲0.0843.99 ▼0.60
Dashboard /wp-admin3.37 ▲0.0750.05 ▼5.00
Posts /wp-admin/edit.php3.43 ▲0.0755.62 ▲0.66
Add New Post /wp-admin/post-new.php5.96 ▲0.0786.52 ▼12.00
Media Library /wp-admin/upload.php3.30 ▲0.0736.54 ▼1.45
Video Player /wp-admin/options-general.php?page=vbwa_settings3.2634.82

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

Filesystem and database footprint
This plugin was installed successfully
Filesystem: 27 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
widget_recent-posts
db_upgraded

Browser metrics Passed 4 tests

Video Block with Ads: an overview of browser usage
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.24 ▲0.031.67 ▼0.3045.67 ▼2.37
Dashboard /wp-admin2,199 ▲225.62 ▼0.0190.65 ▼7.5738.04 ▼5.89
Posts /wp-admin/edit.php2,104 ▲41.98 ▲0.0245.14 ▲3.2535.47 ▲0.16
Add New Post /wp-admin/post-new.php6,195 ▲4,66019.06 ▲0.88946.38 ▲260.4451.42 ▼9.97
Media Library /wp-admin/upload.php1,404 ▲44.25 ▼0.04112.59 ▲9.4748.27 ▲4.44
Video Player /wp-admin/options-general.php?page=vbwa_settings9532.1322.5633.25

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • db_upgraded
    • widget_theysaidso_widget
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_recent-posts
    • can_compress_scripts

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 | 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
Congratulations! This plugin passed the SRP test

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

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
7 plugin tags: block, vast, ads, video, vpaid...

video-block-with-ads/plugin.php 92% from 13 tests

"Video Block with Ads" version 0.71's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
Please make the necessary changes and fix the following:
  • Main file name: The principal plugin file should be the same as the plugin slug ("video-block-with-ads.php" instead of "plugin.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | An overview of files in this plugin; executable files are not allowed
Success! There were no dangerous files found in this plugin38,054 lines of code in 24 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript89,63117,67230,591
JSON2006,885
PHP46029333
CSS8466232
Sass21113

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
Everything seems fine, there were no complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity9.50
▷ Minimum class complexity8.00
▷ Maximum class complexity11.00
Average method complexity2.42
▷ Minimum method complexity1.00
▷ Maximum method complexity7.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods12
▷ Static methods00.00%
▷ Public methods1191.67%
▷ Protected methods00.00%
▷ Private methods18.33%
Functions3
▷ Named functions3100.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