84% data-visualizer

Code Review | Data Visualizer

WordPress plugin Data Visualizer scored84%from 54 tests.

About plugin

  • Plugin page: data-visualizer
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.0-3.9
  • WordPress version: 6.3.1
  • First release: Oct 8, 2013
  • Latest release: Apr 20, 2014
  • Number of updates: 5
  • Update frequency: every 38.8 days
  • Top authors: Subhransu Sekhar (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

30+ active /2,597 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
This plugin's installer ran successfully

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

An overview of server-side resources used by Data Visualizer
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0440.29 ▼2.07
Dashboard /wp-admin3.34 ▼0.0047.01 ▼15.44
Posts /wp-admin/edit.php3.39 ▲0.0450.49 ▼0.10
Add New Post /wp-admin/post-new.php5.93 ▲0.0497.17 ▲1.03
Media Library /wp-admin/upload.php3.27 ▲0.0432.73 ▼4.14

Server storage [IO: ▲2.07MB] [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: 61 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-comments
widget_theysaidso_widget
widget_recent-posts
theysaidso_admin_options
db_upgraded
can_compress_scripts

Browser metrics Passed 4 tests

Checking browser requirements for Data Visualizer
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,871 ▲12113.64 ▼0.7112.73 ▲11.0841.20 ▼1.78
Dashboard /wp-admin2,198 ▲185.51 ▼0.0386.08 ▼3.6438.74 ▼2.39
Posts /wp-admin/edit.php2,100 ▲31.96 ▲0.0033.01 ▼4.6135.47 ▼3.45
Add New Post /wp-admin/post-new.php1,526 ▼223.48 ▲0.16644.10 ▼33.3654.91 ▲3.70
Media Library /wp-admin/upload.php1,397 ▼34.21 ▲0.0396.99 ▼11.9541.43 ▼4.13

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
You still need to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_recent-posts
    • widget_recent-comments
    • theysaidso_admin_options
    • widget_theysaidso_widget
    • can_compress_scripts
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
The smoke test was a success, however most plugin functionality was not tested

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
Almost there! Just fix the following items
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/data-visualizer/data-visualizer.php:16

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
4 plugin tags: maps, chart, data visualization, visualization

data-visualizer/data-visualizer.php Passed 13 tests

This is the main PHP file of "Data Visualizer" version 1.1, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
31 characters long description:
A plugin for Data Visualization

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short review of files and their extensions; it is not recommended to include executable files
Everything looks great! No dangerous files found in this plugin24,994 lines of code in 52 files:
LanguageFilesBlank linesComment linesLines of code
JavaScript424,1773,77423,662
CSS81601161,146
PHP1911164
Markdown17022

PHP code Passed 2 tests

This plugin's cyclomatic complexity and code structure detailed below
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.17
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%
Functions5
▷ Named functions5100.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
8 PNG files occupy 0.01MB with 0.01MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
admin/shortcode/visualize_image.png0.81KB0.86KB0.00%
images/stop_white.png2.77KB0.10KB▼ 96.26%
images/pause_white.png2.78KB0.11KB▼ 96.06%
images/play_white.png2.83KB0.19KB▼ 93.40%
images/play_black.png0.50KB0.19KB▼ 63.06%