10% vzaar-media-management

Code Review | Vzaar Media Management

WordPress plugin Vzaar Media Management scored 10% from 54 tests.

About plugin

  • Plugin page: vzaar-media-manag...
  • Plugin version: 1.2
  • PHP version: 7.4.16
  • WordPress compatibility: 2.8-3.3.1
  • WordPress version: 5.8.1
  • First release: Sep 21, 2011
  • Latest release: Feb 6, 2012
  • Number of updates: 12
  • Update frequency: every 11.6 days
  • Top authors: mamun.reza (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 2,875 total downloads

Benchmarks

Plugin footprint 40% from 16 tests

Installer 0% from 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
You still need to fix the following installer errors
  • This plugin did not install gracefully
    • > Deprecated in wp-content/plugins/vzaar-media-management/admin/admin.php+8
    Methods with the same name as their class will not be constructors in a future version of PHP; esa_vzaarAdminPanel has a deprecated constructor

Server metrics [RAM: ▼1.81MB] [CPU: ▼186.08ms] Passed 4 tests

Server-side resources used by Vzaar Media Management
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /1.81 ▼0.9211.13 ▼13.37
Dashboard /wp-admin1.84 ▼1.225.28 ▼28.98
Posts /wp-admin/edit.php1.84 ▼1.275.54 ▼39.12
Add New Post /wp-admin/post-new.php1.84 ▼3.607.14 ▼645.19
Media Library /wp-admin/upload.php1.84 ▼1.175.72 ▼31.01
Settings /wp-admin/admin.php?page=vzaar-media-management1.845.88
Add Media /wp-admin/admin.php?page=vzaarMedia-add1.845.84

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 31 new files
Database: no new tables, 3 new options
New WordPress options
myPlugin_next_update
vzaar_next_update
vzaar_options

Browser metrics Passed 4 tests

An overview of browser requirements for Vzaar Media Management
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /3,738 ▲14216.02 ▼0.057.80 ▼2.2849.68 ▲0.47
Dashboard /wp-admin2,996 ▲635.90 ▼0.05142.54 ▼25.54144.78 ▲20.14
Posts /wp-admin/edit.php2,770 ▲312.59 ▼0.1167.91 ▼0.02103.32 ▲0.82
Add New Post /wp-admin/post-new.php1,626 ▼5718.76 ▲0.07388.83 ▼0.70109.09 ▼10.94
Media Library /wp-admin/upload.php1,784 ▼235.03 ▲0.01135.95 ▼24.26147.04 ▲24.36
Settings /wp-admin/admin.php?page=vzaar-media-management1,4132.6065.7874.85
Add Media /wp-admin/admin.php?page=vzaarMedia-add1,2472.4253.2191.65

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
The following items require your attention
  • Uninstall procedure had uncaught errors
    • > Deprecated in wp-content/plugins/vzaar-media-management/admin/admin.php+8
    Methods with the same name as their class will not be constructors in a future version of PHP; esa_vzaarAdminPanel has a deprecated constructor
  • The uninstall procedure has failed, leaving 3 options in the database
    • vzaar_next_update
    • vzaar_options
    • myPlugin_next_update

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)
These errors were triggered by the plugin
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Deprecated in wp-content/plugins/vzaar-media-management/admin/admin.php+8
    Methods with the same name as their class will not be constructors in a future version of PHP; esa_vzaarAdminPanel has a deprecated constructor
    • > GET request to /wp-admin/admin.php?page=vzaar-media-management
    • > Warning in wp-content/plugins/vzaar-media-management/admin/admin.php+179
    Use of undefined constant VZAARVERSION - assumed 'VZAARVERSION' (this will throw an Error in a future version of PHP)
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Deprecated in wp-content/plugins/vzaar-media-management/admin/vzaar/Vzaar.php+377
    Methods with the same name as their class will not be constructors in a future version of PHP; XMLToArray has a deprecated constructor
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Deprecated in wp-content/plugins/vzaar-media-management/admin/vzaar/AccountType.php+3
    Methods with the same name as their class will not be constructors in a future version of PHP; CostType has a deprecated constructor
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Deprecated in wp-content/plugins/vzaar-media-management/admin/vzaar/AccountType.php+17
    Methods with the same name as their class will not be constructors in a future version of PHP; RightsType has a deprecated constructor
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Deprecated in wp-content/plugins/vzaar-media-management/admin/vzaar/AccountType.php+26
    Methods with the same name as their class will not be constructors in a future version of PHP; AccountType has a deprecated constructor
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Notice in wp-content/plugins/vzaar-media-management/admin/vzaar/OAuth.php+352
    Undefined index: port
  • 5 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Warning in wp-content/plugins/vzaar-media-management/admin/vzaar/Vzaar.php+463
    sizeof(): Parameter must be an array or an object that implements Countable
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Notice in wp-content/plugins/vzaar-media-management/admin/vzaar-media-upload.php+82
    Undefined index: bucket
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Notice in wp-content/plugins/vzaar-media-management/admin/vzaar-media-upload.php+81
    Undefined index: acl
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Notice in wp-content/plugins/vzaar-media-management/admin/vzaar-media-upload.php+83
    Undefined index: policy
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Notice in wp-content/plugins/vzaar-media-management/admin/vzaar-media-upload.php+84
    Undefined index: accesskeyid
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Notice in wp-content/plugins/vzaar-media-management/admin/vzaar-media-upload.php+85
    Undefined index: signature
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Notice in wp-content/plugins/vzaar-media-management/admin/vzaar-media-upload.php+87
    Undefined index: guid
    • > GET request to /wp-admin/admin.php?page=vzaarMedia-add
    • > Notice in wp-content/plugins/vzaar-media-management/admin/vzaar-media-upload.php+88
    Undefined index: key

SRP 0% from 2 tests

🔹 Tests weight: 20 | It is important to ensure that your PHP files perform no action when accessed directly, respecting the single-responsibility principle
Please fix the following items
  • 5× PHP files perform the action of outputting non-empty strings when accessed directly:
    • > /wp-content/plugins/vzaar-media-management/admin/vzaar-media-upload.php
    • > /wp-content/plugins/vzaar-media-management/vzaar-media-management.php
    • > /wp-content/plugins/vzaar-media-management/admin/settings.php
    • > /wp-content/plugins/vzaar-media-management/admin/install.php
    • > /wp-content/plugins/vzaar-media-management/admin/vzaar/index.php
  • 3× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/vzaar-media-management/admin/admin.php:133
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_filter() in wp-content/plugins/vzaar-media-management/admin/vzaar-media-embed.php:12
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/vzaar-media-management/admin/vzaar-shortcodes.php:14

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
  • Screenshots: Add images for these screenshots: #1 (Screenshot Vzaar Account Settings), #2 (Screenshot Vzaar Media Upload and List), #3 (Screenshot Edit Vzaar Media Information), #4 (Screenshot Add Vzaar Media to the Editor), #5 (Screenshot Show Details for the Media), #6 (Screenshot View Shortcode with Editor)
You can look at the official readme.txt

vzaar-media-management/vzaar-media-management.php Passed 13 tests

The entry point to "Vzaar Media Management" version 1.2 is a PHP file that has certain tags in its header comment area
84 characters long description:
This is a Vzaar Media (audio & video) Management plugin developed by eSoftArena Ltd.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Success! There were no dangerous files found in this plugin2,275 lines of code in 22 files:
LanguageFilesBlank linesComment linesLines of code
PHP195076802,075
CSS2198177
JavaScript12223

PHP code Passed 2 tests

Cyclomatic complexity and code structure are the fingerprint of this plugin
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.25
Average class complexity7.24
▷ Minimum class complexity1.00
▷ Maximum class complexity29.00
Average method complexity2.54
▷ Minimum method complexity1.00
▷ Maximum method complexity18.00
Code structure
Namespaces0
Interfaces1
Traits0
Classes32
▷ Abstract classes00.00%
▷ Concrete classes32100.00%
▷ Final classes00.00%
Methods142
▷ Static methods3222.54%
▷ Public methods13192.25%
▷ Protected methods21.41%
▷ Private methods96.34%
Functions9
▷ Named functions9100.00%
▷ Anonymous functions00.00%
Constants29
▷ Global constants517.24%
▷ Class constants2482.76%
▷ Public constants24100.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
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
admin/images/v.png1.17KB0.27KB▼ 77.01%