84% stock-tools

Code Review | Stock Tools

WordPress plugin Stock Tools scored84%from 54 tests.

About plugin

  • Plugin page: stock-tools
  • Plugin version: 1.1
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-3.5.1
  • WordPress version: 6.3.1
  • First release: Feb 15, 2013
  • Latest release: May 4, 2013
  • Number of updates: 6
  • Update frequency: every 14.5 days
  • Top authors: Developdaly (100%)

Code review

54 tests

User reviews

5 reviews

Install metrics

100+ active /7,528 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
This plugin's installer ran successfully

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

Server-side resources used by Stock Tools
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0137.26 ▼0.21
Dashboard /wp-admin3.32 ▲0.0146.44 ▼4.40
Posts /wp-admin/edit.php3.37 ▲0.0148.87 ▲3.34
Add New Post /wp-admin/post-new.php5.90 ▲0.0190.88 ▼7.30
Media Library /wp-admin/upload.php3.24 ▲0.0135.76 ▲1.69

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

A short overview of filesystem and database impact
No storage issues were detected
Filesystem: 2 new files
Database: no new tables, 6 new options
New WordPress options
widget_recent-posts
can_compress_scripts
theysaidso_admin_options
widget_recent-comments
widget_theysaidso_widget
db_upgraded

Browser metrics Passed 4 tests

Stock Tools: an overview of browser usage
Normal browser usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲5413.30 ▼1.141.71 ▲0.1438.14 ▼3.25
Dashboard /wp-admin2,206 ▲184.89 ▼0.99107.58 ▲5.2139.05 ▼3.66
Posts /wp-admin/edit.php2,089 ▲212.02 ▼0.0340.31 ▲6.9335.94 ▼0.54
Add New Post /wp-admin/post-new.php1,535 ▲1617.80 ▼5.24691.45 ▲85.2452.61 ▼12.95
Media Library /wp-admin/upload.php1,385 ▼04.21 ▼0.0495.66 ▼4.7140.09 ▼3.59

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
You still need to fix the following
  • This plugin does not fully uninstall, leaving 6 options in the database
    • widget_theysaidso_widget
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • widget_recent-posts
    • db_upgraded

Smoke tests 75% from 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 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
The following issues need your attention
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_shortcode() in wp-content/plugins/stock-tools/stock-tools.php:17

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 Passed 29 tests

readme.txt Passed 16 tests

It's important to format your readme.txt file correctly as it is parsed for the public listing of your plugin
6 plugin tags: ticker, stocks, yahoo finance, shortcode, graph...

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

The principal PHP file in "Stock Tools" v. 1.1 is loaded by WordPress automatically on each request
72 characters long description:
A WordPress plugin with a set of tools for displaying stock information.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | This is an overview of file extensions present in this plugin and a short test that no dangerous files are bundled with this plugin
Everything looks great! No dangerous files found in this plugin42 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP1173042

PHP code Passed 2 tests

This is a short overview of cyclomatic complexity and code structure for this plugin
No cyclomatic complexity issues were detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.11
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%
Functions2
▷ Named functions2100.00%
▷ Anonymous functions00.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