84% aino-notification-block

Code Review | Aino Notification Banner Block

WordPress plugin Aino Notification Banner Block scored84%from 54 tests.

About plugin

  • Plugin page: aino-notification...
  • Plugin version: 1.0.0
  • PHP compatiblity: 7.0+
  • PHP version: 7.4.16
  • WordPress compatibility: 5.8-5.9
  • WordPress version: 6.3.1
  • First release: Oct 1, 2021
  • Latest release: Jan 26, 2022
  • Number of updates: 7
  • Update frequency: every 18.6 days
  • Top authors: elmastudio (100%)

Code review

54 tests

User reviews

1 review

Install metrics

200+ active /1,776 total downloads

Benchmarks

Plugin footprint 83% from 16 tests

Installer Passed 1 test

🔺 Critical test (weight: 50) | The install procedure must perform silently
Install script ran successfully

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

A check of server-side resources used by Aino Notification Banner Block
Normal server usage
PageMemory (MB)CPU Time (ms)
Home /3.50 ▲0.0432.10 ▼8.13
Dashboard /wp-admin3.33 ▲0.0340.26 ▼6.02
Posts /wp-admin/edit.php3.38 ▲0.0256.53 ▲8.82
Add New Post /wp-admin/post-new.php5.91 ▲0.0378.33 ▼25.71
Media Library /wp-admin/upload.php3.25 ▲0.0233.46 ▲0.37

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

How much does this plugin use your filesystem and database?
The plugin installed successfully
Filesystem: 12 new files
Database: no new tables, 6 new options
New WordPress options
db_upgraded
widget_recent-comments
widget_theysaidso_widget
can_compress_scripts
widget_recent-posts
theysaidso_admin_options

Browser metrics Passed 4 tests

Aino Notification Banner Block: an overview of browser usage
This plugin has a minimal impact on browser resources
PageNodesMemory (MB)Script (ms)Layout (ms)
Home /2,838 ▲10313.52 ▼1.047.08 ▲5.1144.62 ▼5.67
Dashboard /wp-admin2,209 ▲215.86 ▲0.99116.30 ▲12.5542.54 ▼2.79
Posts /wp-admin/edit.php2,089 ▼02.03 ▲0.0040.73 ▲1.7336.79 ▲2.27
Add New Post /wp-admin/post-new.php6,417 ▲4,88428.35 ▲5.03925.16 ▲323.1863.31 ▲14.87
Media Library /wp-admin/upload.php1,388 ▼04.18 ▼0.0394.93 ▼3.7640.09 ▼9.23

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

🔸 Tests weight: 35 | Checking the uninstaller removed all traces of the plugin
These items require your attention
  • The uninstall procedure has failed, leaving 6 options in the database
    • db_upgraded
    • can_compress_scripts
    • widget_recent-posts
    • widget_theysaidso_widget
    • widget_recent-comments
    • 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 applies for WordPress plugins as well - please make sure your PHP files perform no actions when accessed directly
Please fix the following items
  • 1× PHP files trigger server errors when accessed directly:
    • > PHP Fatal error
      Uncaught Error: Call to undefined function add_action() in wp-content/plugins/aino-notification-block/notification-block.php:54

User-side errors Passed 1 test

🔹 Test weight: 20 | This is just a short smoke test looking for browser issues
Everything seems fine on the user side

Optimizations

Plugin configuration 93% from 29 tests

readme.txt Passed 16 tests

Perhaps the most important file in your plugin readme.txt gets parsed in order to generate the public listing of your plugin
8 plugin tags: notification, alert, aino, banner, gutenberg...

aino-notification-block/notification-block.php 85% from 13 tests

This is the main PHP file of "Aino Notification Banner Block" version 1.0.0, providing information about the plugin in the header fields and serving as the principal entry point to the plugin's functions
Please make the necessary changes and fix the following:
  • Text Domain: If you choose to specify the text domain, it must be the same as the plugin slug; optional since WordPress version 4.6
  • Main file name: Even though not officially enforced, the main plugin file should be the same as the plugin slug ("aino-notification-block.php" instead of "notification-block.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
No dangerous file extensions were detected111 lines of code in 8 files:
LanguageFilesBlank linesComment linesLines of code
JSON10071
PHP3112437
JavaScript2002
CSS2321

PHP code Passed 2 tests

An short overview of logical lines of code, cyclomatic complexity, and other code metrics
This plugin has no cyclomatic complexity problems
Cyclomatic complexity
Average complexity per logical line of code0.00
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

It is recommended to compress PNG files in your plugin to minimize bandwidth usage
No PNG files were detected