83% kento-3d-model-viewer

Code Review | Kento 3D Model Viewer

WordPress plugin Kento 3D Model Viewer scored83%from 54 tests.

About plugin

  • Plugin page: kento-3d-model-vi...
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-4.2.2
  • WordPress version: 6.3.1
  • First release: Dec 19, 2013
  • Latest release: Jun 9, 2015
  • Number of updates: 6
  • Update frequency: every 90.2 days
  • Top authors: kentothemes (100%)

Code review

54 tests

User reviews

9 reviews

Install metrics

100+ active /7,592 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
The plugin installed gracefully, with no errors

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

Analyzing server-side resources used by Kento 3D Model Viewer
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0139.04 ▼0.70
Dashboard /wp-admin3.32 ▲0.0147.13 ▼3.69
Posts /wp-admin/edit.php3.37 ▲0.0145.70 ▼8.22
Add New Post /wp-admin/post-new.php5.90 ▲0.0183.27 ▼21.08
Media Library /wp-admin/upload.php3.24 ▲0.0139.61 ▲3.77

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

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

Browser metrics Passed 4 tests

A check of browser resources used by Kento 3D Model Viewer
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,820 ▲5914.33 ▲0.052.20 ▲0.2642.63 ▲0.83
Dashboard /wp-admin2,197 ▲205.79 ▲0.1487.42 ▼4.8240.56 ▼3.08
Posts /wp-admin/edit.php2,102 ▼12.05 ▲0.0335.77 ▼7.2437.20 ▲0.07
Add New Post /wp-admin/post-new.php1,528 ▼123.24 ▲0.03617.67 ▼62.4955.27 ▼3.10
Media Library /wp-admin/upload.php1,402 ▲54.23 ▲0.0798.70 ▼0.7845.24 ▼0.09

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
The following items require your attention
  • Zombie WordPress options detected upon uninstall: 6 options
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-comments
    • can_compress_scripts
    • widget_theysaidso_widget
    • widget_recent-posts

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though everything seems fine, this is not an exhaustive test

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
Please fix the following
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/kento-3d-model-viewer/index.php:21

User-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no browser errors were triggered
Everything seems fine, but this is not an exhaustive test

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
Please fix the following attributes:
  • Donate link: Please fix this invalid url: ""
  • Screenshots: These screenshots do not have images: #1 (3D model Display on Post), #2 (3D model Display shortcodes.)
You can take inspiration from this readme.txt

kento-3d-model-viewer/index.php 92% from 13 tests

The main file in "Kento 3D Model Viewer" v. 1.0 serves as a complement to information provided in readme.txt and as the entry point to the plugin
The following require your attention:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("kento-3d-model-viewer.php" instead of "index.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of programming languages used in this plugin; dangerous file extensions are not allowed
There were no executable files found in this plugin3,903 lines of code in 3 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript25827203,860
PHP1241643

PHP code Passed 2 tests

Analyzing cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.00
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%
Functions4
▷ Named functions4100.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
3 PNG files occupy 0.22MB with 0.14MB in potential savings
Potential savings
Compression of 3 random PNG files using pngquant
FileSize - originalSize - compressedSavings
screenshot-1.png129.27KB46.01KB▼ 64.41%
scripts/kento_3dmv.png5.10KB1.26KB▼ 75.33%
screenshot-2.png91.59KB47.43KB▼ 48.21%