90% corona-virus-alert-bar

Code Review | Coronavirus Alert Bar

WordPress plugin Coronavirus Alert Bar scored90%from 54 tests.

About plugin

  • Plugin page: corona-virus-aler...
  • Plugin version: 1.0.4
  • PHP compatiblity: 5.4+
  • PHP version: 7.4.16
  • WordPress compatibility: 4.7.0-5.7
  • WordPress version: 6.3.1
  • First release: Apr 16, 2020
  • Latest release: May 10, 2021
  • Number of updates: 12
  • Update frequency: every 32.5 days
  • Top authors: braceomatic88 (100%)

Code review

54 tests

User reviews

2 reviews

Install metrics

100+ active /2,654 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 successfully, without throwing any errors or notices

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

A check of server-side resources used by Coronavirus Alert Bar
No issues were detected with server-side resource usage
PageMemory (MB)CPU Time (ms)
Home /3.78 ▲0.0545.98 ▼0.18
Dashboard /wp-admin3.61 ▲0.0451.92 ▼4.84
Posts /wp-admin/edit.php3.72 ▲0.0447.06 ▼8.55
Add New Post /wp-admin/post-new.php6.19 ▲0.0490.19 ▼12.61
Media Library /wp-admin/upload.php3.53 ▲0.0439.59 ▲4.27

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

Filesystem and database footprint
This plugin installed successfully
Filesystem: 20 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts
theysaidso_admin_options
widget_recent-comments

Browser metrics Passed 4 tests

A check of browser resources used by Coronavirus Alert Bar
Minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,918 ▲17213.82 ▼0.508.69 ▲6.8850.37 ▲4.35
Dashboard /wp-admin2,198 ▲215.67 ▲0.0290.51 ▼15.2439.49 ▼8.29
Posts /wp-admin/edit.php2,097 ▼32.06 ▲0.0537.89 ▲2.8029.72 ▼6.66
Add New Post /wp-admin/post-new.php1,545 ▲1423.18 ▲0.07649.08 ▲12.4151.34 ▼2.93
Media Library /wp-admin/upload.php1,403 ▲34.21 ▲0.0298.31 ▼0.4543.53 ▼0.56

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

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

Smoke tests Passed 4 tests

Server-side errors Passed 1 test

🔹 Test weight: 20 | A smoke test targeting server-side errors
Even though no errors were found, this is by no means an exhaustive test

SRP Passed 2 tests

🔹 Tests weight: 20 | A shallow check of the single-responsibility principle; PHP files should perform no action - including output of placeholder text - and trigger no errors when accessed directly
The SRP test was a success

User-side errors Passed 1 test

🔹 Test weight: 20 | Just a short smoke test targeting errors on the browser (console and network errors and warnings)
Everything seems fine on the user side

Optimizations

Plugin configuration 96% from 29 tests

readme.txt Passed 16 tests

The readme.txt file is undoubtedly the most important file in your plugin, preparing it for public listing on WordPress.org
No tags were found

corona-virus-alert-bar/coronavirus-alert-bar.php 92% from 13 tests

The entry point to "Coronavirus Alert Bar" version 1.0.4 is a PHP file that has certain tags in its header comment area
You should first fix the following items:
  • Main file name: Please rename the main PHP file in this plugin to the plugin slug ("corona-virus-alert-bar.php" instead of "coronavirus-alert-bar.php")

Code Analysis Passed 3 tests

File types Passed 1 test

🔸 Test weight: 35 | There should be no dangerous file extensions present in any WordPress plugin
There were no executable files found in this plugin12,781 lines of code in 7 files:
LanguageFilesBlank linesComment linesLines of code
SVG40139,401
CSS21,497163,135
PHP13913245

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.30
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

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
PNG images were not found in this plugin