83% gold-price-chart-widget

Code Review | Live Gold Price & Silver Price Charts Widgets

WordPress plugin Live Gold Price & Silver Price Charts Widgets scored83%from 54 tests.

About plugin

  • Plugin page: gold-price-chart-...
  • Plugin version: 2.4
  • PHP version: 7.4.16
  • WordPress compatibility: 4.6-5.3.2
  • WordPress version: 6.3.1
  • First release: Jul 22, 2014
  • Latest release: Jan 20, 2020
  • Number of updates: 64
  • Update frequency: every 31.4 days
  • Top authors: GoldBroker (100%)

Code review

54 tests

User reviews

9 reviews

Install metrics

1,000+ active /23,493 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | All plugins must install correctly, without throwing any errors, warnings, or notices
This plugin's installer ran successfully

Server metrics [RAM: ▲0.17MB] [CPU: ▼2.84ms] Passed 4 tests

This is a short check of server-side resources used by Live Gold Price & Silver Price Charts Widgets
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.66 ▲0.1937.46 ▼3.16
Dashboard /wp-admin3.46 ▲0.1645.66 ▼2.55
Posts /wp-admin/edit.php3.58 ▲0.2244.71 ▲0.31
Add New Post /wp-admin/post-new.php6.05 ▲0.1684.87 ▼4.15
Media Library /wp-admin/upload.php3.39 ▲0.1634.67 ▼1.51

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

Input-output and database impact of this plugin
The plugin installed successfully
Filesystem: 15 new files
Database: no new tables, 15 new options
New WordPress options
widget_gb_gold_live_price_widget
widget_theysaidso_widget
db_upgraded
widget_gb_platinum_live_price_widget
widget_gb_silver_chart_widget
widget_gb_palladium_live_price_widget
widget_gb_silver_live_price_widget
theysaidso_admin_options
can_compress_scripts
widget_gb_platinum_chart_widget
...

Browser metrics Passed 4 tests

This is an overview of browser requirements for Live Gold Price & Silver Price Charts Widgets
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,814 ▲5314.36 ▲0.021.91 ▲0.2138.44 ▼10.53
Dashboard /wp-admin2,195 ▲185.54 ▼0.1185.54 ▼3.9137.93 ▼2.17
Posts /wp-admin/edit.php2,060 ▼402.04 ▲0.0835.68 ▼0.9329.79 ▼6.88
Add New Post /wp-admin/post-new.php1,526 ▼023.32 ▲0.36600.04 ▼52.5753.31 ▼23.64
Media Library /wp-admin/upload.php1,397 ▼34.25 ▲0.13100.04 ▼10.8741.80 ▼6.29

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
  • Zombie WordPress options were found after uninstall: 15 options
    • widget_gb_platinum_chart_widget
    • widget_gb_silver_live_price_widget
    • can_compress_scripts
    • widget_gb_palladium_live_price_widget
    • db_upgraded
    • widget_gb_all_metals_table_widget
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_gb_silver_chart_widget
    • widget_gb_platinum_live_price_widget
    • ...

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A shallow check that no server-side errors were triggered
The smoke test was a success, however most plugin functionality was not tested

SRP 50% from 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
Please fix the following
  • 1× GET requests to PHP files have triggered server-side errors or warnings:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/gold-price-chart-widget/gold-price-chart-widget.php:13

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 75% from 16 tests

The readme.txt file uses markdown syntax to describe your plugin to the world
Attributes that require attention:
  • Tags: You are using too many tags: 11 tag instead of maximum 10
  • Screenshots: Add images for these screenshots: #1 (An example of the live gold price chart widget.), #2 (The settings screen in wp-admin/widgets.php.), #3 (An example of the gold price widget), #4 (An example of the silver price widget)
  • Donate link: Please fix this invalid url: ""
  • Plugin Name: Please replace "Plugin Name" with the name of your plugin on the first line ( === gold-price-chart-widget === )
Please take inspiration from this readme.txt

gold-price-chart-widget/gold-price-chart-widget.php Passed 13 tests

The main PHP script in "Live Gold Price & Silver Price Charts Widgets" version 2.4 is automatically included on every request by WordPress
120 characters long description:
Live gold and silver price chart widgets. Once activated go to Widgets and drag the Gold Price Chart in the widget area.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | Executable files are considered dangerous and should not be included with any WordPress plugin
No dangerous file extensions were detected770 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP19519445
PO File4158228325

PHP code Passed 2 tests

A brief analysis of cyclomatic complexity and code structure for this plugin
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.12
Average class complexity1.92
▷ Minimum class complexity1.00
▷ Maximum class complexity5.00
Average method complexity1.60
▷ Minimum method complexity1.00
▷ Maximum method complexity5.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes13
▷ Abstract classes430.77%
▷ Concrete classes969.23%
▷ Final classes00.00%
Methods22
▷ Static methods00.00%
▷ Public methods836.36%
▷ Protected methods1463.64%
▷ Private methods00.00%
Functions2
▷ Named functions150.00%
▷ Anonymous functions150.00%
Constants0
▷ Global constants00.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
No PNG images were found in this plugin