90% back-button-widget

Code Review | Back Button Widget

WordPress plugin Back Button Widget scored90%from 54 tests.

About plugin

  • Plugin page: back-button-widget
  • Plugin version: 1.6.4
  • PHP version: 7.4.16
  • WordPress compatibility: 4.4-6.3
  • WordPress version: 6.3.1
  • First release: Aug 3, 2017
  • Latest release: Sep 28, 2023
  • Number of updates: 42
  • Update frequency: every 53.5 days
  • Top authors: algoritmika (88.1%)wpcodefactory (14.29%)

Code review

54 tests

User reviews

10 reviews

Install metrics

6,000+ active /57,565 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
Installer ran successfully

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

Analyzing server-side resources used by Back Button Widget
This plugin has minimal impact on server resources
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0142.94 ▼0.48
Dashboard /wp-admin3.36 ▲0.0549.47 ▼3.58
Posts /wp-admin/edit.php3.41 ▲0.0551.76 ▲1.47
Add New Post /wp-admin/post-new.php5.94 ▲0.05107.40 ▼1.32
Media Library /wp-admin/upload.php3.28 ▲0.0540.98 ▲1.95
Back Button /wp-admin/options-general.php?page=alg-back-button-settings3.2535.86

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

A short overview of filesystem and database impact
This plugin installed successfully
Filesystem: 8 new files
Database: no new tables, 8 new options
New WordPress options
alg_back_button_widget_version
widget_recent-posts
db_upgraded
widget_alg_back_button_wp_widget
widget_theysaidso_widget
theysaidso_admin_options
can_compress_scripts
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by Back Button Widget
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,793 ▲3214.25 ▼0.481.72 ▲0.0140.20 ▼1.11
Dashboard /wp-admin2,199 ▲225.65 ▲0.0890.35 ▼3.1239.66 ▲0.87
Posts /wp-admin/edit.php2,104 ▲41.99 ▼0.0439.59 ▲5.9138.03 ▲2.28
Add New Post /wp-admin/post-new.php1,531 ▲523.01 ▼0.22700.20 ▲40.8957.34 ▼8.10
Media Library /wp-admin/upload.php1,404 ▲44.13 ▲0.04114.43 ▼6.0147.00 ▼0.27
Back Button /wp-admin/options-general.php?page=alg-back-button-settings1,1182.0427.8534.89

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

🔸 Tests weight: 35 | Verifying that this plugin uninstalls completely without leaving any traces
These items require your attention
  • The uninstall procedure has failed, leaving 8 options in the database
    • db_upgraded
    • theysaidso_admin_options
    • widget_alg_back_button_wp_widget
    • widget_theysaidso_widget
    • widget_recent-posts
    • widget_recent-comments
    • alg_back_button_widget_version
    • can_compress_scripts

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

🔹 Tests weight: 20 | The single-responsibility principle applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Congratulations! This plugin passed the SRP test

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
Everything seems fine, but this is not an exhaustive test

Optimizations

Plugin configuration Passed 29 tests

readme.txt Passed 16 tests

Often overlooked, readme.txt is one of the most important files in your plugin
2 plugin tags: back button widget, back button

back-button-widget/back-button-widget.php Passed 13 tests

The main file in "Back Button Widget" v. 1.6.4 serves as a complement to information provided in readme.txt and as the entry point to the plugin
33 characters long description:
Back button widget for WordPress.

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
Everything looks great! No dangerous files found in this plugin644 lines of code in 5 files:
LanguageFilesBlank linesComment linesLines of code
PHP575305644

PHP code Passed 2 tests

An overview of cyclomatic complexity and code structure
This plugin has no cyclomatic complexity issues
Cyclomatic complexity
Average complexity per logical line of code0.67
Average class complexity16.67
▷ Minimum class complexity9.00
▷ Maximum class complexity28.00
Average method complexity3.04
▷ Minimum method complexity1.00
▷ Maximum method complexity16.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes3
▷ Abstract classes00.00%
▷ Concrete classes3100.00%
▷ Final classes133.33%
Methods23
▷ Static methods14.35%
▷ Public methods23100.00%
▷ Protected methods00.00%
▷ Private methods00.00%
Functions5
▷ Named functions5100.00%
▷ Anonymous functions00.00%
Constants2
▷ Global constants2100.00%
▷ Class constants00.00%
▷ Public constants00.00%

Plugin size Passed 2 tests

Image compression Passed 2 tests

PNG files should be compressed to save space and minimize bandwidth usage
No PNG images were found in this plugin