84% wp-youtube-counters

Code Review | WP YouTube Counters

WordPress plugin WP YouTube Counters scored84%from 54 tests.

About plugin

  • Plugin page: wp-youtube-counters
  • Plugin version: 0.2
  • PHP version: 7.4.16
  • WordPress compatibility: 4.3-4.6.1
  • WordPress version: 6.3.1
  • First release: Oct 8, 2016
  • Latest release: Oct 10, 2016
  • Number of updates: 3
  • Update frequency: every 0.7 days
  • Top authors: mateusz.adamus (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /783 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully

Server metrics [RAM: ▲0.01MB] [CPU: ▼10.80ms] Passed 4 tests

Server-side resources used by WP YouTube Counters
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0236.90 ▼7.26
Dashboard /wp-admin3.32 ▼0.0249.73 ▼16.64
Posts /wp-admin/edit.php3.38 ▲0.0247.88 ▼2.77
Add New Post /wp-admin/post-new.php5.91 ▲0.0284.66 ▼16.33
Media Library /wp-admin/upload.php3.25 ▲0.0234.00 ▼2.98

Server storage [IO: ▲0.01MB] [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: 3 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-comments
theysaidso_admin_options
db_upgraded
widget_recent-posts
can_compress_scripts

Browser metrics Passed 4 tests

This is an overview of browser requirements for WP YouTube Counters
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,825 ▲7914.82 ▲0.561.92 ▲0.1639.44 ▼0.16
Dashboard /wp-admin2,203 ▲185.83 ▼0.06100.83 ▼10.1040.50 ▼0.89
Posts /wp-admin/edit.php2,089 ▼02.05 ▼0.0138.09 ▲0.3135.23 ▲1.03
Add New Post /wp-admin/post-new.php1,537 ▲2323.44 ▲5.76687.43 ▲8.9859.01 ▲6.00
Media Library /wp-admin/upload.php1,382 ▼64.19 ▼0.05104.50 ▼8.6542.77 ▼8.82

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
Please fix the following items
  • Zombie WordPress options were found after uninstall: 6 options
    • theysaidso_admin_options
    • widget_recent-posts
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 2 tests

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
The following issues need your attention
  • 1× PHP files output text when accessed directly:
    • > /wp-content/plugins/wp-youtube-counters/wp-youtube-counters.php

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)
There were no browser issues found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

Don't ignore readme.txt as it is the file that instructs WordPress.org on how to present your plugin to the world
Attributes that need to be fixed:
  • Plugin Name: Please specify the plugin name on the first line ( === wp-youtube-counters === )
The official readme.txt might help

wp-youtube-counters/wp-youtube-counters.php Passed 13 tests

The primary PHP file in "WP YouTube Counters" version 0.2 is used by WordPress to initiate all plugin functionality
71 characters long description:
Shortcodes to show YouTube channel's subscribers and video views count.

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 detected105 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP13016105

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.26
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%
Functions10
▷ Named functions10100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.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
There are no PNG files in this plugin