84% wp-dashboard-beacon

Code Review | Dashboard Beacon

WordPress plugin Dashboard Beacon scored 84% from 54 tests.

About plugin

  • Plugin page: wp-dashboard-beacon
  • Plugin version: 1.2.0
  • PHP version: 7.4.16
  • WordPress compatibility: 3.5.0-4.5.2
  • WordPress version: 6.3.1
  • First release: Oct 11, 2015
  • Latest release: May 14, 2016
  • Number of updates: 19
  • Update frequency: every 11.6 days
  • Top authors: janhenckens (100%)

Code review

54 tests

User reviews

1 review

Install metrics

10+ active / 1,322 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | Checking the installer triggered no errors
Install script ran successfully

Server metrics [RAM: ▲0.03MB] [CPU: ▼1.51ms] Passed 4 tests

Server-side resources used by Dashboard Beacon
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.48 ▲0.0238.33 ▼3.75
Dashboard /wp-admin3.34 ▲0.0448.47 ▼1.90
Posts /wp-admin/edit.php3.39 ▲0.0451.55 ▲6.75
Add New Post /wp-admin/post-new.php5.92 ▲0.0489.28 ▼6.50
Media Library /wp-admin/upload.php3.27 ▲0.0436.45 ▲6.12
Dashboard Beacon /wp-admin/tools.php?page=dashboard_beacon3.2433.24

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

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

Browser metrics Passed 4 tests

This is an overview of browser requirements for Dashboard Beacon
This plugin renders optimally with no browser resource issues detected
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,806 ▲7113.17 ▼1.131.77 ▼0.2345.06 ▼2.95
Dashboard /wp-admin2,215 ▲274.86 ▼1.02105.91 ▼9.1642.88 ▲1.11
Posts /wp-admin/edit.php2,098 ▲92.00 ▼0.0439.35 ▲3.2436.06 ▼0.15
Add New Post /wp-admin/post-new.php1,533 ▲1923.04 ▲5.61631.84 ▼10.6960.56 ▼6.32
Media Library /wp-admin/upload.php1,394 ▲64.26 ▲0.1094.85 ▼0.0440.83 ▼0.87
Dashboard Beacon /wp-admin/tools.php?page=dashboard_beacon8791.9827.2226.52

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

🔸 Tests weight: 35 | The uninstall procedure must remove all plugin files and extra database tables
Please fix the following items
  • The uninstall procedure has failed, leaving 6 options in the database
    • widget_recent-posts
    • can_compress_scripts
    • widget_recent-comments
    • db_upgraded
    • widget_theysaidso_widget
    • theysaidso_admin_options

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
Even though no errors were found, 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
Please fix the following
  • 2× GET requests to PHP files return non-empty strings:
    • > /wp-content/plugins/wp-dashboard-beacon/public/partials/wp-dashboard-beacon-public-display.php
    • > /wp-content/plugins/wp-dashboard-beacon/admin/partials/wp-dashboard-beacon-admin-display.php

User-side errors Passed 1 test

🔹 Test weight: 20 | This is a smoke test targeting browser errors/issues
There were no browser issues found

Optimizations

Plugin configuration 97% from 29 tests

readme.txt 94% from 16 tests

The readme.txt file is important because it is parsed by WordPress.org for the public listing of your plugin
These attributes need to be fixed:
  • Plugin Name: "Plugin Name" should be replaced with the name of your plugin on the first line ( === wp-dashboard-beacon === )
You can look at the official readme.txt

wp-dashboard-beacon/wp-dashboard-beacon.php Passed 13 tests

The main PHP file in "Dashboard Beacon" ver. 1.2.0 adds more information about the plugin and also serves as the entry point for this plugin
65 characters long description:
Easily integrate a Helpscout Beacon in your dashboard or website.

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | A short glimpse at programming languages used with this plugin and a check that no dangerous files are present
Good job! No executable or dangerous file extensions detected754 lines of code in 19 files:
LanguageFilesBlank linesComment linesLines of code
PHP12148560521
PO File15778142
JavaScript485591
CSS2080

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
All good! No complexity issues found
Cyclomatic complexity
Average complexity per logical line of code0.17
Average class complexity4.57
▷ Minimum class complexity1.00
▷ Maximum class complexity19.00
Average method complexity1.66
▷ Minimum method complexity1.00
▷ Maximum method complexity8.00
Code structure
Namespaces0
Interfaces0
Traits0
Classes7
▷ Abstract classes00.00%
▷ Concrete classes7100.00%
▷ Final classes00.00%
Methods38
▷ Static methods25.26%
▷ Public methods3386.84%
▷ Protected methods00.00%
▷ Private methods513.16%
Functions3
▷ Named functions3100.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
4 PNG files occupy 0.16MB with 0.09MB in potential savings
Potential savings
Compression of 4 random PNG files using pngquant
FileSize - originalSize - compressedSavings
icon-128x128.png7.66KB3.59KB▼ 53.12%
screenshot-1.png98.62KB27.46KB▼ 72.15%
icon-256x256.png14.88KB7.77KB▼ 47.77%
banner-772x250.png39.96KB15.83KB▼ 60.39%