78% kulu-valley-video-auto-embed

Code Review | Kulu Valley Video Embed

WordPress plugin Kulu Valley Video Embed scored78%from 54 tests.

About plugin

  • Plugin page: kulu-valley-video...
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.8.1
  • WordPress version: 6.3.1
  • First release: Aug 7, 2013
  • Latest release: Jun 19, 2014
  • Number of updates: 6
  • Update frequency: every 99.3 days
  • Top authors: rtweedie (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /809 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
The plugin installed successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.03MB] [CPU: ▼3.45ms] Passed 4 tests

Analyzing server-side resources used by Kulu Valley Video Embed
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.49 ▲0.0343.16 ▼5.31
Dashboard /wp-admin3.34 ▲0.0344.61 ▼5.20
Posts /wp-admin/edit.php3.45 ▲0.1046.60 ▼0.20
Add New Post /wp-admin/post-new.php5.92 ▲0.0383.35 ▼3.10
Media Library /wp-admin/upload.php3.26 ▲0.0335.89 ▲0.87
Kulu Valley Embed /wp-admin/upload.php?page=kulu-embed3.2334.16

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

Input-output and database impact of this plugin
This plugin was installed successfully
Filesystem: 8 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
db_upgraded
can_compress_scripts
theysaidso_admin_options
widget_theysaidso_widget
widget_recent-posts

Browser metrics Passed 4 tests

Checking browser requirements for Kulu Valley Video Embed
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,804 ▲5813.25 ▼1.431.84 ▲0.0240.41 ▼4.35
Dashboard /wp-admin2,210 ▲195.83 ▲0.9596.22 ▼10.0639.24 ▼3.83
Posts /wp-admin/edit.php2,093 ▲42.04 ▲0.0439.90 ▲1.8234.88 ▲1.12
Add New Post /wp-admin/post-new.php1,522 ▼2223.29 ▲5.11641.81 ▲35.1753.09 ▼1.31
Media Library /wp-admin/upload.php1,389 ▲44.23 ▲0.01101.11 ▼2.4541.61 ▼3.23
Kulu Valley Embed /wp-admin/upload.php?page=kulu-embed8332.0322.9626.45

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

🔸 Tests weight: 35 | It is important to correctly uninstall your plugin, without leaving any traces
The following items require your attention
  • This plugin did not uninstall successfully, leaving 6 options in the database
    • widget_recent-comments
    • can_compress_scripts
    • widget_recent-posts
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for server-side errors
Everything seems fine, however this is by no means an exhaustive test

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
The following issues need your attention
  • 1× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/kulu-valley-video-auto-embed/wp-kuluvalley-embed.php
  • 5× PHP files trigger errors when accessed directly with GET requests:
    • > PHP Fatal error
      Uncaught Error: Class 'WpKuluValleyEmbedCore' not found in wp-content/plugins/kulu-valley-video-auto-embed/classes/wpkve-admin.php:10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_nonce_field() in wp-content/plugins/kulu-valley-video-auto-embed/views/_form.php:5
    • > PHP Notice
      Undefined index: wp_version in wp-content/plugins/kulu-valley-video-auto-embed/wp-kuluvalley-embed.php on line 10
    • > PHP Fatal error
      Uncaught Error: Call to undefined function wp_nonce_field() in wp-content/plugins/kulu-valley-video-auto-embed/views/_form.php:5
    • > PHP Fatal error
      Uncaught Error: Class 'WpKuluValleyEmbedCore' not found in wp-content/plugins/kulu-valley-video-auto-embed/classes/wpkve-frontend.php:10

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)
Everything seems fine on the user side

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 88% from 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
These attributes need your attention:
  • Contributors: Plugin contributors not specified
  • Screenshots: Screenshot #1 (Settings page for Kulu Valley video embed) image missing
The official readme.txt is a good inspiration

kulu-valley-video-auto-embed/wp-kuluvalley-embed.php 92% from 13 tests

The primary PHP file in "Kulu Valley Video Embed" version 1.1 is used by WordPress to initiate all plugin functionality
Please take the time to fix the following:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("kulu-valley-video-auto-embed.php" instead of "wp-kuluvalley-embed.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
Everything looks great! No dangerous files found in this plugin221 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
PHP67396196
Markdown123025

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.49
Average class complexity7.67
▷ Minimum class complexity4.00
▷ Maximum class complexity12.00
Average method complexity2.25
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods16
▷ Static methods743.75%
▷ Public methods1593.75%
▷ Protected methods00.00%
▷ Private methods16.25%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants3
▷ Global constants3100.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
1 PNG file occupies 0.02MB with 0.02MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
Kulu-valley-video-embed-options.png25.32KB9.76KB▼ 61.44%