74% stock-ticker

Code Review | Stock Ticker

WordPress plugin Stock Ticker scored74%from 54 tests.

About plugin

  • Plugin page: stock-ticker
  • Plugin version: 3.23.4
  • PHP compatiblity: 5.6+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.9-6.3
  • WordPress version: 6.3.1
  • First release: Feb 11, 2014
  • Latest release: Aug 14, 2023
  • Number of updates: 83
  • Update frequency: every 41.8 days
  • Top authors: urkekg (100%)

Code review

54 tests

User reviews

21 reviews

Install metrics

3,000+ active /119,454 total downloads

Benchmarks

Plugin footprint 65% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | It is important to correctly install your plugin, without throwing errors or notices
Installer ran successfully

Server metrics [RAM: ▲0.34MB] [CPU: ▼6.71ms] Passed 4 tests

This is a short check of server-side resources used by Stock Ticker
This plugin does not affect your website's performance
PageMemory (MB)CPU Time (ms)
Home /3.70 ▲0.2440.77 ▼3.46
Dashboard /wp-admin3.68 ▲0.3752.90 ▼5.68
Posts /wp-admin/edit.php3.79 ▲0.4453.71 ▲8.83
Add New Post /wp-admin/post-new.php6.26 ▲0.3785.12 ▼23.77
Media Library /wp-admin/upload.php3.60 ▲0.3736.31 ▲6.08
Stock Ticker /wp-admin/options-general.php?page=stock-ticker3.6133.33

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

A short overview of filesystem and database impact
The plugin installed successfully
Filesystem: 23 new files
Database: 1 new table, 9 new options
New tables
wp_stock_ticker_data
New WordPress options
stockticker_db_ver
db_upgraded
widget_stock_ticker
widget_recent-posts
theysaidso_admin_options
can_compress_scripts
stockticker_version
widget_recent-comments
widget_theysaidso_widget

Browser metrics Passed 4 tests

This is an overview of browser requirements for Stock Ticker
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,924 ▲17813.70 ▼0.599.06 ▲7.4641.86 ▼2.49
Dashboard /wp-admin2,211 ▲375.56 ▲0.0380.35 ▼3.4237.79 ▼0.25
Posts /wp-admin/edit.php2,119 ▲192.09 ▲0.1040.04 ▼2.7436.45 ▼0.50
Add New Post /wp-admin/post-new.php1,542 ▲1623.39 ▼0.25655.46 ▲39.4050.25 ▲0.52
Media Library /wp-admin/upload.php1,422 ▲194.17 ▼0.1196.42 ▼0.3642.92 ▲2.32
Stock Ticker /wp-admin/options-general.php?page=stock-ticker1,9612.5850.8342.80

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • Zombie tables detected upon uninstall: 1 table
    • wp_stock_ticker_data
  • The uninstall procedure has failed, leaving 9 options in the database
    • can_compress_scripts
    • stockticker_db_ver
    • widget_stock_ticker
    • theysaidso_admin_options
    • db_upgraded
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • stockticker_version

Smoke tests 75% 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 | The single-responsibility principle: PHP files have to remain inert when accessed directly, throwing no errors and performing no actions
Almost there! Just fix the following items
  • 1× PHP files trigger server-side errors or warnings when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Class 'WP_Widget' not found in wp-content/plugins/stock-ticker/inc/widget.php:21

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine on the user side

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

You should put a lot of thought into formatting readme.txt as it is used by WordPress.org to prepare the public listing of your plugin
6 plugin tags: trading, ticker, stock ticker, forex, sotck quote...

stock-ticker/stock-ticker.php Passed 13 tests

"Stock Ticker" version 3.23.4's main PHP file describes plugin functionality and also serves as the entry point to any WordPress functionality
100 characters long description:
Easy add customizable moving or static ticker tapes with stock information for custom stock symbols.

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
There were no executable files found in this plugin3,068 lines of code in 15 files:
LanguageFilesBlank linesComment linesLines of code
PHP53155852,204
JavaScript650131566
Sass22031249
CSS21249

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
There were no cyclomatic complexity issued detected
Cyclomatic complexity
Average complexity per logical line of code0.32
Average class complexity68.00
▷ Minimum class complexity44.00
▷ Maximum class complexity98.00
Average method complexity4.87
▷ Minimum method complexity1.00
▷ Maximum method complexity42.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes00.00%
Methods52
▷ Static methods47.69%
▷ Public methods4892.31%
▷ Protected methods00.00%
▷ Private methods47.69%
Functions12
▷ Named functions12100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants00.00%
▷ Class constants2100.00%
▷ Public constants2100.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

All PNG images should be compressed to minimize bandwidth usage for end users
1 compressed PNG file occupies 0.00MB
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
assets/img/paypal.png1.57KB1.58KB0.00%