78% 123on

Code Review | 123on video plugin

WordPress plugin 123on video plugin scored78%from 54 tests.

About plugin

  • Plugin page: 123on
  • Plugin version: 1.0.5
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0-6.3.1
  • WordPress version: 6.3.1
  • First release: Apr 5, 2022
  • Latest release: Oct 12, 2023
  • Number of updates: 17
  • Update frequency: every 32.7 days
  • Top authors: 123on (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active /841 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 gracefully, with no errors

Server metrics [RAM: ▲0.14MB] [CPU: ▲0.54ms] Passed 4 tests

This is a short check of server-side resources used by 123on video plugin
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.59 ▲0.1342.58 ▲3.78
Dashboard /wp-admin3.43 ▲0.1244.32 ▼2.77
Posts /wp-admin/edit.php3.54 ▲0.1845.51 ▼1.08
Add New Post /wp-admin/post-new.php6.06 ▲0.1791.18 ▲2.24
Media Library /wp-admin/upload.php3.35 ▲0.1237.93 ▲5.33

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

Analyzing filesystem and database footprints of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 55 new files
Database: no new tables, 8 new options
New WordPress options
widget_theysaidso_widget
P123ON_installed
db_upgraded
can_compress_scripts
widget_recent-posts
P123ON_version
widget_recent-comments
theysaidso_admin_options

Browser metrics Passed 4 tests

A check of browser resources used by 123on video plugin
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,816 ▲5514.69 ▲0.331.61 ▲0.0441.38 ▲0.36
Dashboard /wp-admin2,225 ▲575.57 ▼0.1082.57 ▼3.8865.58 ▲22.98
Posts /wp-admin/edit.php2,124 ▲241.98 ▲0.0139.34 ▲3.2138.81 ▲0.21
Add New Post /wp-admin/post-new.php6,235 ▲4,69824.74 ▲6.61993.65 ▲366.0249.22 ▼12.46
Media Library /wp-admin/upload.php1,430 ▲364.14 ▼0.03100.40 ▲2.7374.53 ▲30.67
Videos /wp-admin/admin.php?page=vue-app#/1,0325.8572.8931.75
Add new /wp-admin/admin.php?page=vue-app#/add-new1,6376.5080.3952.83

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • The uninstall procedure has failed, leaving 8 options in the database
    • widget_recent-comments
    • P123ON_version
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-posts
    • theysaidso_admin_options
    • P123ON_installed
    • can_compress_scripts

Smoke tests 50% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the server (in the Apache logs)
Even though everything seems fine, this is not an exhaustive test

SRP 50% 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
The following issues need your attention
  • 2× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_REST_Controller' not found in wp-content/plugins/123on/includes/Api/Example.php:10
    • > PHP Fatal error
      Uncaught Error: Class 'WP_REST_Controller' not found in wp-content/plugins/123on/includes/Api.php:9

User-side errors 0% from 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Please fix the following browser errors
  • 2 occurences, only the last one shown
    • > GET request to /wp-admin/admin.php?page=vue-app#/
    • > Network (severe)
    wp-json/v2/video_123on/1 - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/admin.php?page=vue-app#/add-new
    • > Console-api (severe) in unknown
    webpack:///./node_modules/vue/dist/vue.esm.js? 628:14 "[Vue warn]: Invalid component name: \"Add New\". Component names should conform to valid custom element name in html5 specification."
    • > GET request to /wp-admin/admin.php?page=vue-app#/add-new
    • > Console-api (severe) in unknown
    webpack:///./node_modules/vue/dist/vue.esm.js? 628:14 "[Vue warn]: Invalid component name: \"Hotspot Table\". Component names should conform to valid custom element name in html5 specification."
    • > GET request to /wp-admin/admin.php?page=vue-app#/add-new
    • > Console-api (severe) in unknown
    webpack:///./node_modules/vue/dist/vue.esm.js? 628:14 "[Vue warn]: Invalid component name: \"Draggable Hotspot\". Component names should conform to valid custom element name in html5 specification."
    • > GET request to /wp-admin/admin.php?page=vue-app#/add-new
    • > Network (severe)
    wp-json/v2/video_123on/pages - Failed to load resource: the server responded with a status of 404 (Not Found)
    • > GET request to /wp-admin/admin.php?page=vue-app#/add-new
    • > Network (severe)
    wp-json/v2/video_123on/products - Failed to load resource: the server responded with a status of 404 (Not Found)

Optimizations

Plugin configuration 90% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Please fix the following attributes:
  • Screenshots: These screenshots have no corresponding images in /assets: #1 (This is your video list. Here you can navigate through your different videos and projects.), #2 (The navigation is really simple, you have your videos and your shortcut to create a new video.), #3 (This is the editor that you will you use to make your video interactive. Upload, and put in your hotspots.)
You can look at the official readme.txt

123on/plugin.php 85% from 13 tests

The principal PHP file in "123on video plugin" v. 1.0.5 is loaded by WordPress automatically on each request
You should first fix the following items:
  • Text Domain: The text domain name should consist of only dashes and lowercase characters
  • Main file name: It is recommended to name the main PHP file as the plugin slug ("123on.php" instead of "plugin.php")

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
Good job! No executable or dangerous file extensions detected3,449 lines of code in 36 files:
LanguageFilesBlank linesComment linesLines of code
Vuejs Component1216761,354
JavaScript124616361,042
PHP6134249568
CSS2520423
SVG40062

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
Although this was not an exhaustive test, there were no cyclomatic complexity issues detected
Cyclomatic complexity
Average complexity per logical line of code0.21
Average class complexity7.33
▷ Minimum class complexity2.00
▷ Maximum class complexity18.00
Average method complexity1.84
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces2
Interfaces0
Traits0
Classes6
▷ Abstract classes00.00%
▷ Concrete classes6100.00%
▷ Final classes116.67%
Methods45
▷ Static methods12.22%
▷ Public methods4293.33%
▷ Protected methods00.00%
▷ Private methods36.67%
Functions0
▷ Named functions00.00%
▷ Anonymous functions00.00%
Constants6
▷ Global constants6100.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
14 PNG files occupy 0.22MB with 0.05MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
assets/img/copy.png0.42KB0.48KB0.00%
assets/img/plugin-icon.png0.40KB0.34KB▼ 14.77%
assets/img/transparent-hotspot.png0.28KB0.12KB▼ 55.12%
assets/img/popup-arrow-left.png0.47KB0.31KB▼ 33.95%
assets/img/hotspot-yellow.png1.14KB1.14KB0.00%