83% audio-tube

Code Review | Audio Tube

WordPress plugin Audio Tube scored 83% from 54 tests.

About plugin

  • Plugin page: audio-tube
  • Plugin version: 1.2.2
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.6
  • WordPress version: 5.8.1
  • First release: Nov 17, 2011
  • Latest release: Aug 25, 2013
  • Number of updates: 44
  • Update frequency: every 14.7 days
  • Top authors: brasofilo (100%)

Code review

54 tests

User reviews

3 reviews

Install metrics

500+ active / 29,452 total downloads

Benchmarks

Plugin footprint Passed 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed gracefully, with no errors

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

Analyzing server-side resources used by Audio Tube
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /2.84 ▲0.1239.91 ▲19.02
Dashboard /wp-admin3.07 ▲0.0247.28 ▲1.18
Posts /wp-admin/edit.php3.12 ▲0.0247.30 ▲3.67
Add New Post /wp-admin/post-new.php5.43 ▲0.0095.60 ▼550.33
Media Library /wp-admin/upload.php3.01 ▲0.0144.09 ▼0.61
AudioTube /wp-admin/tools.php?page=audio_tube2.9629.69

Server storage [IO: ▲0.14MB] [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: 28 new files
Database: no new tables, 1 new option
New WordPress options
AudioTubePlayerOptions

Browser metrics Passed 4 tests

Audio Tube: an overview of browser usage
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,708 ▲11215.86 ▲0.0011.25 ▲0.8954.28 ▲6.95
Dashboard /wp-admin2,975 ▲446.06 ▲0.04143.11 ▼9.85115.71 ▼8.28
Posts /wp-admin/edit.php2,744 ▲52.69 ▼0.0166.76 ▼3.2295.34 ▲2.10
Add New Post /wp-admin/post-new.php1,686 ▲318.82 ▲0.01413.53 ▲18.87116.82 ▼0.41
Media Library /wp-admin/upload.php1,812 ▲55.02 ▲0.03165.74 ▲4.65123.53 ▼2.39
AudioTube /wp-admin/tools.php?page=audio_tube1,5552.1559.45122.23

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
Uninstaller ran successfully

Smoke tests 25% from 4 tests

Server-side errors 0% from 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
These server-side errors were triggered
    • > GET request to /wp-admin/tools.php?page=audio_tube
    • > Deprecated in wp-content/plugins/audio-tube/inc/page-admin.php+8
    Function get_magic_quotes_gpc() is deprecated

SRP 0% from 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
Please fix the following
  • 1× PHP files perform the task of outputting text when accessed with GET requests:
    • > /wp-content/plugins/audio-tube/inc/page-admin.php
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function register_activation_hook() in wp-content/plugins/audio-tube/audio-tube.php:38

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file describes your plugin functionality and requirements and it is parsed to prepare the your plugin's listing
7 plugin tags: music, youtube, audio, mp3, audio player...

audio-tube/audio-tube.php 92% from 13 tests

The primary PHP file in "Audio Tube" version 1.2.2 is used by WordPress to initiate all plugin functionality
It is important to fix the following:
  • Text Domain: The text domain is optional since WordPress version 4.6; if you do specify it, it must be the same as the plugin slug

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 plugin714 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
PHP485135403
PO File271105226
JavaScript17061
CSS16324

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
No complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.28
Average class complexity12.00
▷ Minimum class complexity4.00
▷ Maximum class complexity20.00
Average method complexity2.83
▷ Minimum method complexity1.00
▷ Maximum method complexity17.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes2
▷ Abstract classes00.00%
▷ Concrete classes2100.00%
▷ Final classes00.00%
Methods12
▷ Static methods18.33%
▷ Public methods12100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
14 PNG files occupy 0.06MB with 0.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
images/7-large-no-tc.png4.05KB2.66KB▼ 34.29%
images/play-tub.png4.88KB1.74KB▼ 64.43%
images/2-no-bar.png2.30KB1.35KB▼ 41.19%
images/8-large-tc.png7.55KB4.38KB▼ 42.03%
images/5-medium-no-tc.png3.79KB2.60KB▼ 31.38%