89% sql-chart-builder

Code Review | SQL Chart Builder

WordPress plugin SQL Chart Builder scored89%from 54 tests.

About plugin

  • Plugin page: sql-chart-builder
  • Plugin version: 2.3.6
  • PHP version: 7.4.16
  • WordPress compatibility: 5.0.0-6.4.1
  • WordPress version: 6.3.1
  • First release: Feb 25, 2016
  • Latest release: Nov 20, 2023
  • Number of updates: 56
  • Update frequency: every 50.5 days
  • Top authors: Elvin.Haci (100%)

Code review

54 tests

User reviews

21 reviews

Install metrics

900+ active /21,822 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 successfully, without throwing any errors or notices

Server metrics [RAM: ▲0.04MB] [CPU: ▼1.56ms] Passed 4 tests

A check of server-side resources used by SQL Chart Builder
Server-side resource usage in normal parameters
PageMemory (MB)CPU Time (ms)
Home /3.51 ▲0.0434.77 ▼4.68
Dashboard /wp-admin3.34 ▲0.0349.15 ▼3.43
Posts /wp-admin/edit.php3.39 ▲0.0349.92 ▲4.16
Add New Post /wp-admin/post-new.php5.94 ▲0.0595.30 ▲9.62
Media Library /wp-admin/upload.php3.26 ▲0.0331.79 ▼2.27
My SQL Charts /wp-admin/edit.php?post_type=gvn_schart3.3737.38
Add New /wp-admin/post-new.php?post_type=gvn_schart3.4642.58

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

Analyzing filesystem and database footprints of this plugin
The plugin installed successfully
Filesystem: 19 new files
Database: no new tables, 7 new options
New WordPress options
theysaidso_admin_options
db_upgraded
guaven_sqlcharts_already_installed_2
can_compress_scripts
widget_recent-posts
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

Checking browser requirements for SQL Chart Builder
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,952 ▲19014.81 ▲0.1810.99 ▲9.3638.36 ▼6.72
Dashboard /wp-admin2,243 ▲695.28 ▼0.3698.61 ▲7.0639.61 ▲0.94
Posts /wp-admin/edit.php2,148 ▲452.67 ▲0.6844.77 ▲5.5238.83 ▲4.14
Add New Post /wp-admin/post-new.php6,236 ▲4,71019.45 ▼3.77928.92 ▲183.8437.88 ▼12.12
Media Library /wp-admin/upload.php1,448 ▲514.90 ▲0.69100.87 ▼1.0744.48 ▼0.43
My SQL Charts /wp-admin/edit.php?post_type=gvn_schart1,9832.5143.2540.44
Add New /wp-admin/post-new.php?post_type=gvn_schart1,9253.2460.3671.77

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

🔸 Tests weight: 35 | All plugins must uninstall correctly, removing their source code and extra database tables they might have created
These items require your attention
  • This plugin does not fully uninstall, leaving 7 options in the database
    • widget_theysaidso_widget
    • db_upgraded
    • widget_recent-comments
    • guaven_sqlcharts_already_installed_2
    • can_compress_scripts
    • widget_recent-posts
    • theysaidso_admin_options

Smoke tests Passed 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 Passed 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a shallow check for browser errors
No browser errors were detected

Optimizations

Plugin configuration 86% from 29 tests

readme.txt 94% from 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
Please fix the following attributes: You can take inspiration from this readme.txt

sql-chart-builder/guaven_sqlcharts.php 77% from 13 tests

Analyzing the main PHP file in "SQL Chart Builder" version 2.3.6
You should first fix the following items:
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("sql-chart-builder.php" instead of "guaven_sqlcharts.php")
  • Domain Path: The domain path points to a folder that does not exist ("/languages")
  • Text Domain: The text domain name should consist of only dashes and lowercase characters

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 plugin1,409 lines of code in 9 files:
LanguageFilesBlank linesComment linesLines of code
PHP6192281,254
JavaScript21119127
CSS19828

PHP code Passed 2 tests

A short review of cyclomatic complexity and code structure
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.39
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%
Functions41
▷ Named functions3790.24%
▷ Anonymous functions49.76%
Constants1
▷ Global constants1100.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
8 PNG files occupy 0.06MB with 0.03MB in potential savings
Potential savings
Compression of 5 random PNG files using pngquant
FileSize - originalSize - compressedSavings
asset/img/3dpie.png8.24KB3.63KB▼ 55.98%
asset/img/polar.png14.52KB6.79KB▼ 53.25%
asset/img/line.png4.72KB2.64KB▼ 44.14%
asset/img/pie.png7.82KB3.53KB▼ 54.79%
asset/img/donut.png8.83KB3.97KB▼ 55.06%