84% bolt-news

Code Review | Bolt News

WordPress plugin Bolt News scored84%from 54 tests.

About plugin

  • Plugin page: bolt-news
  • Plugin version: 1.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5-4.7
  • WordPress version: 6.3.1
  • First release: Apr 27, 2017
  • Latest release: Apr 27, 2017
  • Number of updates: 2
  • Update frequency: every 2.0 days
  • Top authors: riangraphics (100%)

Code review

54 tests

User reviews

1 review

Install metrics

20+ active /752 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Verifying that this plugin installs correctly without errors
The plugin installed gracefully, with no errors

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

A check of server-side resources used by Bolt News
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.47 ▲0.0040.21 ▼0.49
Dashboard /wp-admin3.31 ▲0.0147.85 ▼0.90
Posts /wp-admin/edit.php3.36 ▲0.0144.36 ▼2.51
Add New Post /wp-admin/post-new.php5.89 ▲0.0184.75 ▼16.16
Media Library /wp-admin/upload.php3.24 ▲0.0140.94 ▲3.22

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

Input-output and database impact of this plugin
There were no storage issued detected upon installing this plugin
Filesystem: 3 new files
Database: no new tables, 6 new options
New WordPress options
widget_theysaidso_widget
widget_recent-posts
db_upgraded
widget_recent-comments
can_compress_scripts
theysaidso_admin_options

Browser metrics Passed 4 tests

Bolt News: an overview of browser usage
There were no issues detected in relation to browser resource usage
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,800 ▲3914.24 ▼0.111.64 ▲0.0442.03 ▼4.99
Dashboard /wp-admin2,194 ▲145.55 ▼0.0483.25 ▼15.2774.42 ▲36.79
Posts /wp-admin/edit.php2,111 ▲111.99 ▲0.0036.18 ▲1.3535.48 ▲0.97
Add New Post /wp-admin/post-new.php1,557 ▲3123.04 ▼0.71698.11 ▲0.8964.10 ▲5.55
Media Library /wp-admin/upload.php1,408 ▲84.15 ▼0.08109.52 ▼4.9383.80 ▲33.35

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
It is recommended to fix the following
  • Zombie WordPress options were found after uninstall: 6 options
    • widget_theysaidso_widget
    • widget_recent-posts
    • can_compress_scripts
    • theysaidso_admin_options
    • widget_recent-comments
    • db_upgraded

Smoke tests 75% from 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | This is a short smoke test looking for server-side errors
Everything seems fine, however this is by no means an exhaustive test

SRP 50% from 2 tests

🔹 Tests weight: 20 | SRP (Single-Responsibility Principle) - PHP files must act as libraries and never output text or perform any action when accessed directly in a browser
Please fix the following items
  • 1× GET requests to PHP files trigger server-side errors or Error 500 responses:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/bolt-news/bolt-news.php:15

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: simple, toast, sidebar, sidebar news, news...

bolt-news/bolt-news.php Passed 13 tests

The primary PHP file in "Bolt News" version 1.0 is used by WordPress to initiate all plugin functionality
26 characters long description:
Simple short News sidebar.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short check of programming languages and file extensions; no executable files are allowed
No dangerous file extensions were detected215 lines of code in 1 file:
LanguageFilesBlank linesComment linesLines of code
PHP12420215

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
There are no cyclomatic complexity problems detected for this plugin
Cyclomatic complexity
Average complexity per logical line of code0.16
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%
Functions6
▷ Named functions6100.00%
▷ Anonymous functions00.00%
Constants0
▷ Global constants00.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

Often times overlooked, PNG files can occupy unnecessary space in your plugin
1 PNG file occupies 0.00MB with 0.00MB in potential savings
Potential savings
Compression of 1 random PNG file using pngquant
FileSize - originalSize - compressedSavings
img/icon.png0.49KB0.33KB▼ 32.81%